<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><link rel="stylesheet" type="text/css" href="style.css" /><script type="text/javascript" src="highlight.js"></script></head><body><pre><span id="local-6989586621679717220"></span><span class="hs-pragma">{-# LANGUAGE FlexibleContexts #-}</span><span>
</span><span id="line-2"></span><span class="hs-pragma">{-# LANGUAGE RankNTypes #-}</span><span>
</span><span id="line-3"></span><span>
</span><span id="line-4"></span><span class="hs-comment">-----------------------------------------------------------------------------</span><span>
</span><span id="line-5"></span><span class="hs-comment">-- |</span><span>
</span><span id="line-6"></span><span class="hs-comment">-- Module      :  Distribution.Simple.GHC.Internal</span><span>
</span><span id="line-7"></span><span class="hs-comment">-- Copyright   :  Isaac Jones 2003-2007</span><span>
</span><span id="line-8"></span><span class="hs-comment">--</span><span>
</span><span id="line-9"></span><span class="hs-comment">-- Maintainer  :  cabal-devel@haskell.org</span><span>
</span><span id="line-10"></span><span class="hs-comment">-- Portability :  portable</span><span>
</span><span id="line-11"></span><span class="hs-comment">--</span><span>
</span><span id="line-12"></span><span class="hs-comment">-- This module contains functions shared by GHC (Distribution.Simple.GHC)</span><span>
</span><span id="line-13"></span><span class="hs-comment">-- and GHC-derived compilers.</span><span>
</span><span id="line-14"></span><span>
</span><span id="line-15"></span><span class="hs-keyword">module</span><span> </span><span class="hs-identifier">Distribution.Simple.GHC.Internal</span><span> </span><span class="hs-special">(</span><span>
</span><span id="line-16"></span><span>        </span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#configureToolchain"><span class="hs-identifier">configureToolchain</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-17"></span><span>        </span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#getLanguages"><span class="hs-identifier">getLanguages</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-18"></span><span>        </span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#getExtensions"><span class="hs-identifier">getExtensions</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-19"></span><span>        </span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#targetPlatform"><span class="hs-identifier">targetPlatform</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-20"></span><span>        </span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#getGhcInfo"><span class="hs-identifier">getGhcInfo</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-21"></span><span>        </span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#componentCcGhcOptions"><span class="hs-identifier">componentCcGhcOptions</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-22"></span><span>        </span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#componentCmmGhcOptions"><span class="hs-identifier">componentCmmGhcOptions</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-23"></span><span>        </span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#componentCxxGhcOptions"><span class="hs-identifier">componentCxxGhcOptions</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-24"></span><span>        </span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#componentAsmGhcOptions"><span class="hs-identifier">componentAsmGhcOptions</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-25"></span><span>        </span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#componentGhcOptions"><span class="hs-identifier">componentGhcOptions</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-26"></span><span>        </span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#mkGHCiLibName"><span class="hs-identifier">mkGHCiLibName</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-27"></span><span>        </span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#mkGHCiProfLibName"><span class="hs-identifier">mkGHCiProfLibName</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-28"></span><span>        </span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#filterGhciFlags"><span class="hs-identifier">filterGhciFlags</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-29"></span><span>        </span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#ghcLookupProperty"><span class="hs-identifier">ghcLookupProperty</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-30"></span><span>        </span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#getHaskellObjects"><span class="hs-identifier">getHaskellObjects</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-31"></span><span>        </span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#mkGhcOptPackages"><span class="hs-identifier">mkGhcOptPackages</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-32"></span><span>        </span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#substTopDir"><span class="hs-identifier">substTopDir</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-33"></span><span>        </span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#checkPackageDbEnvVar"><span class="hs-identifier">checkPackageDbEnvVar</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-34"></span><span>        </span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#profDetailLevelFlag"><span class="hs-identifier">profDetailLevelFlag</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-35"></span><span>        </span><span class="annot"><span class="hs-comment">-- * GHC platform and version strings</span></span><span>
</span><span id="line-36"></span><span>        </span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#ghcArchString"><span class="hs-identifier">ghcArchString</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-37"></span><span>        </span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#ghcOsString"><span class="hs-identifier">ghcOsString</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-38"></span><span>        </span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#ghcPlatformAndVersionString"><span class="hs-identifier">ghcPlatformAndVersionString</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-39"></span><span>        </span><span class="annot"><span class="hs-comment">-- * Constructing GHC environment files</span></span><span>
</span><span id="line-40"></span><span>        </span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#GhcEnvironmentFileEntry"><span class="hs-identifier">GhcEnvironmentFileEntry</span></a></span><span class="hs-special">(</span><span class="hs-glyph">..</span><span class="hs-special">)</span><span class="hs-special">,</span><span>
</span><span id="line-41"></span><span>        </span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#writeGhcEnvironmentFile"><span class="hs-identifier">writeGhcEnvironmentFile</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-42"></span><span>        </span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#simpleGhcEnvironmentFile"><span class="hs-identifier">simpleGhcEnvironmentFile</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-43"></span><span>        </span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#ghcEnvironmentFileName"><span class="hs-identifier">ghcEnvironmentFileName</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-44"></span><span>        </span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#renderGhcEnvironmentFile"><span class="hs-identifier">renderGhcEnvironmentFile</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-45"></span><span>        </span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#renderGhcEnvironmentFileEntry"><span class="hs-identifier">renderGhcEnvironmentFileEntry</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-46"></span><span> </span><span class="hs-special">)</span><span> </span><span class="hs-keyword">where</span><span>
</span><span id="line-47"></span><span>
</span><span id="line-48"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="../../base/src/Prelude.html#"><span class="hs-identifier">Prelude</span></a></span><span> </span><span class="hs-special">(</span><span class="hs-special">)</span><span>
</span><span id="line-49"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="Distribution.Compat.Prelude.html"><span class="hs-identifier">Distribution.Compat.Prelude</span></a></span><span>
</span><span id="line-50"></span><span>
</span><span id="line-51"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="Distribution.Simple.GHC.ImplInfo.html"><span class="hs-identifier">Distribution.Simple.GHC.ImplInfo</span></a></span><span>
</span><span id="line-52"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="Distribution.Types.ComponentLocalBuildInfo.html"><span class="hs-identifier">Distribution.Types.ComponentLocalBuildInfo</span></a></span><span>
</span><span id="line-53"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="Distribution.Backpack.html"><span class="hs-identifier">Distribution.Backpack</span></a></span><span>
</span><span id="line-54"></span><span class="hs-keyword">import</span><span> </span><span class="hs-keyword">qualified</span><span> </span><span class="annot"><a href="Distribution.InstalledPackageInfo.html"><span class="hs-identifier">Distribution.InstalledPackageInfo</span></a></span><span> </span><span class="hs-keyword">as</span><span> </span><span class="annot"><span class="hs-identifier">IPI</span></span><span>
</span><span id="line-55"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="Distribution.PackageDescription.html"><span class="hs-identifier">Distribution.PackageDescription</span></a></span><span>
</span><span id="line-56"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="Distribution.Lex.html"><span class="hs-identifier">Distribution.Lex</span></a></span><span>
</span><span id="line-57"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="Distribution.Simple.Compiler.html"><span class="hs-identifier">Distribution.Simple.Compiler</span></a></span><span>
</span><span id="line-58"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="Distribution.Simple.Program.GHC.html"><span class="hs-identifier">Distribution.Simple.Program.GHC</span></a></span><span>
</span><span id="line-59"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="Distribution.Simple.Setup.html"><span class="hs-identifier">Distribution.Simple.Setup</span></a></span><span>
</span><span id="line-60"></span><span class="hs-keyword">import</span><span> </span><span class="hs-keyword">qualified</span><span> </span><span class="annot"><a href="Distribution.ModuleName.html"><span class="hs-identifier">Distribution.ModuleName</span></a></span><span> </span><span class="hs-keyword">as</span><span> </span><span class="annot"><span class="hs-identifier">ModuleName</span></span><span>
</span><span id="line-61"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="Distribution.Simple.Program.html"><span class="hs-identifier">Distribution.Simple.Program</span></a></span><span>
</span><span id="line-62"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="Distribution.Simple.LocalBuildInfo.html"><span class="hs-identifier">Distribution.Simple.LocalBuildInfo</span></a></span><span>
</span><span id="line-63"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="Distribution.Types.UnitId.html"><span class="hs-identifier">Distribution.Types.UnitId</span></a></span><span>
</span><span id="line-64"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="Distribution.Types.LocalBuildInfo.html"><span class="hs-identifier">Distribution.Types.LocalBuildInfo</span></a></span><span>
</span><span id="line-65"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="Distribution.Types.TargetInfo.html"><span class="hs-identifier">Distribution.Types.TargetInfo</span></a></span><span>
</span><span id="line-66"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="Distribution.Types.ModuleRenaming.html"><span class="hs-identifier">Distribution.Types.ModuleRenaming</span></a></span><span>
</span><span id="line-67"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="Distribution.Simple.Utils.html"><span class="hs-identifier">Distribution.Simple.Utils</span></a></span><span>
</span><span id="line-68"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="Distribution.Simple.BuildPaths.html"><span class="hs-identifier">Distribution.Simple.BuildPaths</span></a></span><span>
</span><span id="line-69"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="Distribution.System.html"><span class="hs-identifier">Distribution.System</span></a></span><span>
</span><span id="line-70"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="Distribution.Pretty.html"><span class="hs-identifier">Distribution.Pretty</span></a></span><span> </span><span class="hs-special">(</span><span> </span><span class="annot"><a href="Distribution.Pretty.html#prettyShow"><span class="hs-identifier">prettyShow</span></a></span><span> </span><span class="hs-special">)</span><span>
</span><span id="line-71"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="Distribution.Parsec.html"><span class="hs-identifier">Distribution.Parsec</span></a></span><span> </span><span class="hs-special">(</span><span> </span><span class="annot"><a href="Distribution.Parsec.html#simpleParsec"><span class="hs-identifier">simpleParsec</span></a></span><span> </span><span class="hs-special">)</span><span>
</span><span id="line-72"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="Distribution.Utils.NubList.html"><span class="hs-identifier">Distribution.Utils.NubList</span></a></span><span> </span><span class="hs-special">(</span><span> </span><span class="annot"><a href="Distribution.Utils.NubList.html#toNubListR"><span class="hs-identifier">toNubListR</span></a></span><span> </span><span class="hs-special">)</span><span>
</span><span id="line-73"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="Distribution.Verbosity.html"><span class="hs-identifier">Distribution.Verbosity</span></a></span><span>
</span><span id="line-74"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="Distribution.Compat.Stack.html"><span class="hs-identifier">Distribution.Compat.Stack</span></a></span><span>
</span><span id="line-75"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="Distribution.Version.html"><span class="hs-identifier">Distribution.Version</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="Distribution.Types.Version.html#Version"><span class="hs-identifier">Version</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-76"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="Language.Haskell.Extension.html"><span class="hs-identifier">Language.Haskell.Extension</span></a></span><span>
</span><span id="line-77"></span><span>
</span><span id="line-78"></span><span class="hs-keyword">import</span><span> </span><span class="hs-keyword">qualified</span><span> </span><span class="annot"><a href="../../containers/src/Data.Map.html#"><span class="hs-identifier">Data.Map</span></a></span><span> </span><span class="hs-keyword">as</span><span> </span><span class="annot"><span class="hs-identifier">Map</span></span><span>
</span><span id="line-79"></span><span class="hs-keyword">import</span><span> </span><span class="hs-keyword">qualified</span><span> </span><span class="annot"><a href="../../bytestring/src/Data.ByteString.Lazy.Char8.html#"><span class="hs-identifier">Data.ByteString.Lazy.Char8</span></a></span><span> </span><span class="hs-keyword">as</span><span> </span><span class="annot"><span class="hs-identifier">BS</span></span><span>
</span><span id="line-80"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="../../directory/src/System.Directory.html#"><span class="hs-identifier">System.Directory</span></a></span><span>         </span><span class="hs-special">(</span><span> </span><span class="annot"><a href="../../directory/src/System.Directory.html#getDirectoryContents"><span class="hs-identifier">getDirectoryContents</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><a href="../../directory/src/System.Directory.html#getTemporaryDirectory"><span class="hs-identifier">getTemporaryDirectory</span></a></span><span> </span><span class="hs-special">)</span><span>
</span><span id="line-81"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="../../base/src/System.Environment.html#"><span class="hs-identifier">System.Environment</span></a></span><span>       </span><span class="hs-special">(</span><span> </span><span class="annot"><a href="../../base/src/System.Environment.html#getEnv"><span class="hs-identifier">getEnv</span></a></span><span> </span><span class="hs-special">)</span><span>
</span><span id="line-82"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="../../filepath/src/System.FilePath.html#"><span class="hs-identifier">System.FilePath</span></a></span><span>          </span><span class="hs-special">(</span><span> </span><span class="annot"><a href="../../filepath/src/System.FilePath.Windows.html#%3C%2F%3E"><span class="hs-operator">(&lt;/&gt;)</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><a href="../../filepath/src/System.FilePath.Windows.html#%3C.%3E"><span class="hs-operator">(&lt;.&gt;)</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><a href="../../filepath/src/System.FilePath.Windows.html#takeExtension"><span class="hs-identifier">takeExtension</span></a></span><span>
</span><span id="line-83"></span><span>                                </span><span class="hs-special">,</span><span> </span><span class="annot"><a href="../../filepath/src/System.FilePath.Windows.html#takeDirectory"><span class="hs-identifier">takeDirectory</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><a href="../../filepath/src/System.FilePath.Windows.html#takeFileName"><span class="hs-identifier">takeFileName</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-84"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="../../base/src/System.IO.html#"><span class="hs-identifier">System.IO</span></a></span><span>                </span><span class="hs-special">(</span><span> </span><span class="annot"><a href="../../base/src/GHC.IO.Handle.html#hClose"><span class="hs-identifier">hClose</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><a href="../../base/src/GHC.IO.Handle.Text.html#hPutStrLn"><span class="hs-identifier">hPutStrLn</span></a></span><span> </span><span class="hs-special">)</span><span>
</span><span id="line-85"></span><span>
</span><span id="line-86"></span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#targetPlatform"><span class="hs-identifier hs-type">targetPlatform</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="hs-special">[</span><span class="hs-special">(</span><span class="annot"><a href="../../base/src/GHC.Base.html#String"><span class="hs-identifier hs-type">String</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><a href="../../base/src/GHC.Base.html#String"><span class="hs-identifier hs-type">String</span></a></span><span class="hs-special">)</span><span class="hs-special">]</span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="../../base/src/GHC.Maybe.html#Maybe"><span class="hs-identifier hs-type">Maybe</span></a></span><span> </span><span class="annot"><a href="Distribution.System.html#Platform"><span class="hs-identifier hs-type">Platform</span></a></span><span>
</span><span id="line-87"></span><span id="targetPlatform"><span class="annot"><span class="annottext">targetPlatform :: [(String, String)] -&gt; Maybe Platform
</span><a href="Distribution.Simple.GHC.Internal.html#targetPlatform"><span class="hs-identifier hs-var hs-var">targetPlatform</span></a></span></span><span> </span><span id="local-6989586621679717060"><span class="annot"><span class="annottext">[(String, String)]
</span><a href="#local-6989586621679717060"><span class="hs-identifier hs-var">ghcInfo</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; Maybe Platform
</span><a href="Distribution.System.html#platformFromTriple"><span class="hs-identifier hs-var">platformFromTriple</span></a></span><span> </span><span class="annot"><span class="annottext">(String -&gt; Maybe Platform) -&gt; Maybe String -&gt; Maybe Platform
forall (m :: * -&gt; *) a b. Monad m =&gt; (a -&gt; m b) -&gt; m a -&gt; m b
</span><a href="../../base/src/GHC.Base.html#%3D%3C%3C"><span class="hs-operator hs-var">=&lt;&lt;</span></a></span><span> </span><span class="annot"><span class="annottext">String -&gt; [(String, String)] -&gt; Maybe String
forall a b. Eq a =&gt; a -&gt; [(a, b)] -&gt; Maybe b
</span><a href="../../base/src/GHC.List.html#lookup"><span class="hs-identifier hs-var">lookup</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;Target platform&quot;</span></span><span> </span><span class="annot"><span class="annottext">[(String, String)]
</span><a href="#local-6989586621679717060"><span class="hs-identifier hs-var">ghcInfo</span></a></span><span>
</span><span id="line-88"></span><span>
</span><span id="line-89"></span><span class="hs-comment">-- | Adjust the way we find and configure gcc and ld</span><span>
</span><span id="line-90"></span><span class="hs-comment">--</span><span>
</span><span id="line-91"></span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#configureToolchain"><span class="hs-identifier hs-type">configureToolchain</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="Distribution.Simple.GHC.ImplInfo.html#GhcImplInfo"><span class="hs-identifier hs-type">GhcImplInfo</span></a></span><span>
</span><span id="line-92"></span><span>                   </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="Distribution.Simple.Program.Types.html#ConfiguredProgram"><span class="hs-identifier hs-type">ConfiguredProgram</span></a></span><span>
</span><span id="line-93"></span><span>                   </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="../../containers/src/Data.Map.Internal.html#Map"><span class="hs-identifier hs-type">Map</span></a></span><span> </span><span class="annot"><a href="../../base/src/GHC.Base.html#String"><span class="hs-identifier hs-type">String</span></a></span><span> </span><span class="annot"><a href="../../base/src/GHC.Base.html#String"><span class="hs-identifier hs-type">String</span></a></span><span>
</span><span id="line-94"></span><span>                   </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="Distribution.Simple.Program.Db.html#ProgramDb"><span class="hs-identifier hs-type">ProgramDb</span></a></span><span>
</span><span id="line-95"></span><span>                   </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="Distribution.Simple.Program.Db.html#ProgramDb"><span class="hs-identifier hs-type">ProgramDb</span></a></span><span>
</span><span id="line-96"></span><span id="configureToolchain"><span class="annot"><span class="annottext">configureToolchain :: GhcImplInfo
-&gt; ConfiguredProgram -&gt; Map String String -&gt; ProgramDb -&gt; ProgramDb
</span><a href="Distribution.Simple.GHC.Internal.html#configureToolchain"><span class="hs-identifier hs-var hs-var">configureToolchain</span></a></span></span><span> </span><span id="local-6989586621679717056"><span class="annot"><span class="annottext">GhcImplInfo
</span><a href="#local-6989586621679717056"><span class="hs-identifier hs-var">_implInfo</span></a></span></span><span> </span><span id="local-6989586621679717055"><span class="annot"><span class="annottext">ConfiguredProgram
</span><a href="#local-6989586621679717055"><span class="hs-identifier hs-var">ghcProg</span></a></span></span><span> </span><span id="local-6989586621679717054"><span class="annot"><span class="annottext">Map String String
</span><a href="#local-6989586621679717054"><span class="hs-identifier hs-var">ghcInfo</span></a></span></span><span> </span><span class="hs-glyph">=</span><span>
</span><span id="line-97"></span><span>    </span><span class="annot"><span class="annottext">Program -&gt; ProgramDb -&gt; ProgramDb
</span><a href="Distribution.Simple.Program.Db.html#addKnownProgram"><span class="hs-identifier hs-var">addKnownProgram</span></a></span><span> </span><span class="annot"><span class="annottext">Program
</span><a href="Distribution.Simple.Program.Builtin.html#gccProgram"><span class="hs-identifier hs-var">gccProgram</span></a></span><span> </span><span class="hs-special">{</span><span>
</span><span id="line-98"></span><span>      </span><span class="annot"><span class="annottext">programFindLocation :: Verbosity -&gt; ProgramSearchPath -&gt; IO (Maybe (String, [String]))
</span><a href="Distribution.Simple.Program.Types.html#programFindLocation"><span class="hs-identifier hs-var">programFindLocation</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String
-&gt; [String]
-&gt; Verbosity
-&gt; ProgramSearchPath
-&gt; IO (Maybe (String, [String]))
</span><a href="#local-6989586621679717050"><span class="hs-identifier hs-var">findProg</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679717049"><span class="hs-identifier hs-var">gccProgramName</span></a></span><span> </span><span class="annot"><span class="annottext">[String]
</span><a href="#local-6989586621679717048"><span class="hs-identifier hs-var">extraGccPath</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-99"></span><span>      </span><span class="annot"><span class="annottext">programPostConf :: Verbosity -&gt; ConfiguredProgram -&gt; IO ConfiguredProgram
</span><a href="Distribution.Simple.Program.Types.html#programPostConf"><span class="hs-identifier hs-var">programPostConf</span></a></span><span>     </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Verbosity -&gt; ConfiguredProgram -&gt; IO ConfiguredProgram
</span><a href="#local-6989586621679717046"><span class="hs-identifier hs-var">configureGcc</span></a></span><span>
</span><span id="line-100"></span><span>    </span><span class="hs-special">}</span><span>
</span><span id="line-101"></span><span>  </span><span class="annot"><span class="annottext">(ProgramDb -&gt; ProgramDb)
-&gt; (ProgramDb -&gt; ProgramDb) -&gt; ProgramDb -&gt; ProgramDb
forall b c a. (b -&gt; c) -&gt; (a -&gt; b) -&gt; a -&gt; c
</span><a href="../../base/src/GHC.Base.html#."><span class="hs-operator hs-var">.</span></a></span><span> </span><span class="annot"><span class="annottext">Program -&gt; ProgramDb -&gt; ProgramDb
</span><a href="Distribution.Simple.Program.Db.html#addKnownProgram"><span class="hs-identifier hs-var">addKnownProgram</span></a></span><span> </span><span class="annot"><span class="annottext">Program
</span><a href="Distribution.Simple.Program.Builtin.html#ldProgram"><span class="hs-identifier hs-var">ldProgram</span></a></span><span> </span><span class="hs-special">{</span><span>
</span><span id="line-102"></span><span>      </span><span class="annot"><span class="annottext">programFindLocation :: Verbosity -&gt; ProgramSearchPath -&gt; IO (Maybe (String, [String]))
</span><a href="Distribution.Simple.Program.Types.html#programFindLocation"><span class="hs-identifier hs-var">programFindLocation</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String
-&gt; [String]
-&gt; Verbosity
-&gt; ProgramSearchPath
-&gt; IO (Maybe (String, [String]))
</span><a href="#local-6989586621679717050"><span class="hs-identifier hs-var">findProg</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679717043"><span class="hs-identifier hs-var">ldProgramName</span></a></span><span> </span><span class="annot"><span class="annottext">[String]
</span><a href="#local-6989586621679717042"><span class="hs-identifier hs-var">extraLdPath</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-103"></span><span>      </span><span class="annot"><span class="annottext">programPostConf :: Verbosity -&gt; ConfiguredProgram -&gt; IO ConfiguredProgram
</span><a href="Distribution.Simple.Program.Types.html#programPostConf"><span class="hs-identifier hs-var">programPostConf</span></a></span><span>     </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Verbosity -&gt; ConfiguredProgram -&gt; IO ConfiguredProgram
</span><a href="#local-6989586621679717041"><span class="hs-identifier hs-var">configureLd</span></a></span><span>
</span><span id="line-104"></span><span>    </span><span class="hs-special">}</span><span>
</span><span id="line-105"></span><span>  </span><span class="annot"><span class="annottext">(ProgramDb -&gt; ProgramDb)
-&gt; (ProgramDb -&gt; ProgramDb) -&gt; ProgramDb -&gt; ProgramDb
forall b c a. (b -&gt; c) -&gt; (a -&gt; b) -&gt; a -&gt; c
</span><a href="../../base/src/GHC.Base.html#."><span class="hs-operator hs-var">.</span></a></span><span> </span><span class="annot"><span class="annottext">Program -&gt; ProgramDb -&gt; ProgramDb
</span><a href="Distribution.Simple.Program.Db.html#addKnownProgram"><span class="hs-identifier hs-var">addKnownProgram</span></a></span><span> </span><span class="annot"><span class="annottext">Program
</span><a href="Distribution.Simple.Program.Builtin.html#arProgram"><span class="hs-identifier hs-var">arProgram</span></a></span><span> </span><span class="hs-special">{</span><span>
</span><span id="line-106"></span><span>      </span><span class="annot"><span class="annottext">programFindLocation :: Verbosity -&gt; ProgramSearchPath -&gt; IO (Maybe (String, [String]))
</span><a href="Distribution.Simple.Program.Types.html#programFindLocation"><span class="hs-identifier hs-var">programFindLocation</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String
-&gt; [String]
-&gt; Verbosity
-&gt; ProgramSearchPath
-&gt; IO (Maybe (String, [String]))
</span><a href="#local-6989586621679717050"><span class="hs-identifier hs-var">findProg</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679717039"><span class="hs-identifier hs-var">arProgramName</span></a></span><span> </span><span class="annot"><span class="annottext">[String]
</span><a href="#local-6989586621679717038"><span class="hs-identifier hs-var">extraArPath</span></a></span><span>
</span><span id="line-107"></span><span>    </span><span class="hs-special">}</span><span>
</span><span id="line-108"></span><span>  </span><span class="annot"><span class="annottext">(ProgramDb -&gt; ProgramDb)
-&gt; (ProgramDb -&gt; ProgramDb) -&gt; ProgramDb -&gt; ProgramDb
forall b c a. (b -&gt; c) -&gt; (a -&gt; b) -&gt; a -&gt; c
</span><a href="../../base/src/GHC.Base.html#."><span class="hs-operator hs-var">.</span></a></span><span> </span><span class="annot"><span class="annottext">Program -&gt; ProgramDb -&gt; ProgramDb
</span><a href="Distribution.Simple.Program.Db.html#addKnownProgram"><span class="hs-identifier hs-var">addKnownProgram</span></a></span><span> </span><span class="annot"><span class="annottext">Program
</span><a href="Distribution.Simple.Program.Builtin.html#stripProgram"><span class="hs-identifier hs-var">stripProgram</span></a></span><span> </span><span class="hs-special">{</span><span>
</span><span id="line-109"></span><span>      </span><span class="annot"><span class="annottext">programFindLocation :: Verbosity -&gt; ProgramSearchPath -&gt; IO (Maybe (String, [String]))
</span><a href="Distribution.Simple.Program.Types.html#programFindLocation"><span class="hs-identifier hs-var">programFindLocation</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String
-&gt; [String]
-&gt; Verbosity
-&gt; ProgramSearchPath
-&gt; IO (Maybe (String, [String]))
</span><a href="#local-6989586621679717050"><span class="hs-identifier hs-var">findProg</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679717036"><span class="hs-identifier hs-var">stripProgramName</span></a></span><span> </span><span class="annot"><span class="annottext">[String]
</span><a href="#local-6989586621679717035"><span class="hs-identifier hs-var">extraStripPath</span></a></span><span>
</span><span id="line-110"></span><span>    </span><span class="hs-special">}</span><span>
</span><span id="line-111"></span><span>  </span><span class="hs-keyword">where</span><span>
</span><span id="line-112"></span><span>    </span><span id="local-6989586621679717034"><span class="annot"><span class="annottext">compilerDir :: String
</span><a href="#local-6989586621679717034"><span class="hs-identifier hs-var hs-var">compilerDir</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; String
</span><a href="../../filepath/src/System.FilePath.Windows.html#takeDirectory"><span class="hs-identifier hs-var">takeDirectory</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">ConfiguredProgram -&gt; String
</span><a href="Distribution.Simple.Program.Types.html#programPath"><span class="hs-identifier hs-var">programPath</span></a></span><span> </span><span class="annot"><span class="annottext">ConfiguredProgram
</span><a href="#local-6989586621679717055"><span class="hs-identifier hs-var">ghcProg</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-113"></span><span>    </span><span id="local-6989586621679717032"><span class="annot"><span class="annottext">base_dir :: String
</span><a href="#local-6989586621679717032"><span class="hs-identifier hs-var hs-var">base_dir</span></a></span></span><span>     </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; String
</span><a href="../../filepath/src/System.FilePath.Windows.html#takeDirectory"><span class="hs-identifier hs-var">takeDirectory</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679717034"><span class="hs-identifier hs-var">compilerDir</span></a></span><span>
</span><span id="line-114"></span><span>    </span><span id="local-6989586621679717031"><span class="annot"><span class="annottext">mingwBinDir :: String
</span><a href="#local-6989586621679717031"><span class="hs-identifier hs-var hs-var">mingwBinDir</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679717032"><span class="hs-identifier hs-var">base_dir</span></a></span><span> </span><span class="annot"><span class="annottext">String -&gt; String -&gt; String
</span><a href="../../filepath/src/System.FilePath.Windows.html#%3C%2F%3E"><span class="hs-operator hs-var">&lt;/&gt;</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;mingw&quot;</span></span><span> </span><span class="annot"><span class="annottext">String -&gt; String -&gt; String
</span><a href="../../filepath/src/System.FilePath.Windows.html#%3C%2F%3E"><span class="hs-operator hs-var">&lt;/&gt;</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;bin&quot;</span></span><span>
</span><span id="line-115"></span><span>    </span><span id="local-6989586621679717030"><span class="annot"><span class="annottext">isWindows :: Bool
</span><a href="#local-6989586621679717030"><span class="hs-identifier hs-var hs-var">isWindows</span></a></span></span><span>   </span><span class="hs-glyph">=</span><span> </span><span class="hs-keyword">case</span><span> </span><span class="annot"><span class="annottext">OS
</span><a href="Distribution.System.html#buildOS"><span class="hs-identifier hs-var">buildOS</span></a></span><span> </span><span class="hs-keyword">of</span><span> </span><span class="annot"><span class="annottext">OS
</span><a href="Distribution.System.html#Windows"><span class="hs-identifier hs-var">Windows</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">Bool
</span><span class="hs-identifier hs-var">True</span></span><span class="hs-special">;</span><span> </span><span class="annot"><span class="annottext">OS
</span><span class="hs-identifier">_</span></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">Bool
</span><span class="hs-identifier hs-var">False</span></span><span>
</span><span id="line-116"></span><span>    </span><span id="local-6989586621679717027"><span class="annot"><span class="annottext">binPrefix :: String
</span><a href="#local-6989586621679717027"><span class="hs-identifier hs-var hs-var">binPrefix</span></a></span></span><span>   </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;&quot;</span></span><span>
</span><span id="line-117"></span><span>
</span><span id="line-118"></span><span>    </span><span class="annot"><a href="#local-6989586621679717026"><span class="hs-identifier hs-type">maybeName</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="Distribution.Simple.Program.Types.html#Program"><span class="hs-identifier hs-type">Program</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="../../base/src/GHC.Maybe.html#Maybe"><span class="hs-identifier hs-type">Maybe</span></a></span><span> </span><span class="annot"><a href="../../base/src/GHC.IO.html#FilePath"><span class="hs-identifier hs-type">FilePath</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="../../base/src/GHC.Base.html#String"><span class="hs-identifier hs-type">String</span></a></span><span>
</span><span id="line-119"></span><span>    </span><span id="local-6989586621679717026"><span class="annot"><span class="annottext">maybeName :: Program -&gt; Maybe String -&gt; String
</span><a href="#local-6989586621679717026"><span class="hs-identifier hs-var hs-var">maybeName</span></a></span></span><span> </span><span id="local-6989586621679717024"><span class="annot"><span class="annottext">Program
</span><a href="#local-6989586621679717024"><span class="hs-identifier hs-var">prog</span></a></span></span><span>   </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; (String -&gt; String) -&gt; Maybe String -&gt; String
forall b a. b -&gt; (a -&gt; b) -&gt; Maybe a -&gt; b
</span><a href="../../base/src/Data.Maybe.html#maybe"><span class="hs-identifier hs-var">maybe</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">Program -&gt; String
</span><a href="Distribution.Simple.Program.Types.html#programName"><span class="hs-identifier hs-var hs-var">programName</span></a></span><span> </span><span class="annot"><span class="annottext">Program
</span><a href="#local-6989586621679717024"><span class="hs-identifier hs-var">prog</span></a></span><span class="hs-special">)</span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">String -&gt; String
</span><a href="Distribution.Simple.Utils.html#dropExeExtension"><span class="hs-identifier hs-var">dropExeExtension</span></a></span><span> </span><span class="annot"><span class="annottext">(String -&gt; String) -&gt; (String -&gt; String) -&gt; String -&gt; String
forall b c a. (b -&gt; c) -&gt; (a -&gt; b) -&gt; a -&gt; c
</span><a href="../../base/src/GHC.Base.html#."><span class="hs-operator hs-var">.</span></a></span><span> </span><span class="annot"><span class="annottext">String -&gt; String
</span><a href="../../filepath/src/System.FilePath.Windows.html#takeFileName"><span class="hs-identifier hs-var">takeFileName</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-120"></span><span>
</span><span id="line-121"></span><span>    </span><span id="local-6989586621679717049"><span class="annot"><span class="annottext">gccProgramName :: String
</span><a href="#local-6989586621679717049"><span class="hs-identifier hs-var hs-var">gccProgramName</span></a></span></span><span>   </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Program -&gt; Maybe String -&gt; String
</span><a href="#local-6989586621679717026"><span class="hs-identifier hs-var">maybeName</span></a></span><span> </span><span class="annot"><span class="annottext">Program
</span><a href="Distribution.Simple.Program.Builtin.html#gccProgram"><span class="hs-identifier hs-var">gccProgram</span></a></span><span>   </span><span class="annot"><span class="annottext">Maybe String
</span><a href="#local-6989586621679717020"><span class="hs-identifier hs-var">mbGccLocation</span></a></span><span>
</span><span id="line-122"></span><span>    </span><span id="local-6989586621679717043"><span class="annot"><span class="annottext">ldProgramName :: String
</span><a href="#local-6989586621679717043"><span class="hs-identifier hs-var hs-var">ldProgramName</span></a></span></span><span>    </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Program -&gt; Maybe String -&gt; String
</span><a href="#local-6989586621679717026"><span class="hs-identifier hs-var">maybeName</span></a></span><span> </span><span class="annot"><span class="annottext">Program
</span><a href="Distribution.Simple.Program.Builtin.html#ldProgram"><span class="hs-identifier hs-var">ldProgram</span></a></span><span>    </span><span class="annot"><span class="annottext">Maybe String
</span><a href="#local-6989586621679717019"><span class="hs-identifier hs-var">mbLdLocation</span></a></span><span>
</span><span id="line-123"></span><span>    </span><span id="local-6989586621679717039"><span class="annot"><span class="annottext">arProgramName :: String
</span><a href="#local-6989586621679717039"><span class="hs-identifier hs-var hs-var">arProgramName</span></a></span></span><span>    </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Program -&gt; Maybe String -&gt; String
</span><a href="#local-6989586621679717026"><span class="hs-identifier hs-var">maybeName</span></a></span><span> </span><span class="annot"><span class="annottext">Program
</span><a href="Distribution.Simple.Program.Builtin.html#arProgram"><span class="hs-identifier hs-var">arProgram</span></a></span><span>    </span><span class="annot"><span class="annottext">Maybe String
</span><a href="#local-6989586621679717018"><span class="hs-identifier hs-var">mbArLocation</span></a></span><span>
</span><span id="line-124"></span><span>    </span><span id="local-6989586621679717036"><span class="annot"><span class="annottext">stripProgramName :: String
</span><a href="#local-6989586621679717036"><span class="hs-identifier hs-var hs-var">stripProgramName</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Program -&gt; Maybe String -&gt; String
</span><a href="#local-6989586621679717026"><span class="hs-identifier hs-var">maybeName</span></a></span><span> </span><span class="annot"><span class="annottext">Program
</span><a href="Distribution.Simple.Program.Builtin.html#stripProgram"><span class="hs-identifier hs-var">stripProgram</span></a></span><span> </span><span class="annot"><span class="annottext">Maybe String
</span><a href="#local-6989586621679717017"><span class="hs-identifier hs-var">mbStripLocation</span></a></span><span>
</span><span id="line-125"></span><span>
</span><span id="line-126"></span><span>    </span><span class="annot"><a href="#local-6989586621679717016"><span class="hs-identifier hs-type">mkExtraPath</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="../../base/src/GHC.Maybe.html#Maybe"><span class="hs-identifier hs-type">Maybe</span></a></span><span> </span><span class="annot"><a href="../../base/src/GHC.IO.html#FilePath"><span class="hs-identifier hs-type">FilePath</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="../../base/src/GHC.IO.html#FilePath"><span class="hs-identifier hs-type">FilePath</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="hs-special">[</span><span class="annot"><a href="../../base/src/GHC.IO.html#FilePath"><span class="hs-identifier hs-type">FilePath</span></a></span><span class="hs-special">]</span><span>
</span><span id="line-127"></span><span>    </span><span id="local-6989586621679717016"><span class="annot"><span class="annottext">mkExtraPath :: Maybe String -&gt; String -&gt; [String]
</span><a href="#local-6989586621679717016"><span class="hs-identifier hs-var hs-var">mkExtraPath</span></a></span></span><span> </span><span id="local-6989586621679717015"><span class="annot"><span class="annottext">Maybe String
</span><a href="#local-6989586621679717015"><span class="hs-identifier hs-var">mbPath</span></a></span></span><span> </span><span id="local-6989586621679717014"><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679717014"><span class="hs-identifier hs-var">mingwPath</span></a></span></span><span> </span><span class="hs-glyph">|</span><span> </span><span class="annot"><span class="annottext">Bool
</span><a href="#local-6989586621679717030"><span class="hs-identifier hs-var">isWindows</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">[String]
</span><a href="#local-6989586621679717013"><span class="hs-identifier hs-var">mbDir</span></a></span><span> </span><span class="annot"><span class="annottext">[String] -&gt; [String] -&gt; [String]
forall a. [a] -&gt; [a] -&gt; [a]
</span><a href="../../base/src/GHC.Base.html#%2B%2B"><span class="hs-operator hs-var">++</span></a></span><span> </span><span class="hs-special">[</span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679717014"><span class="hs-identifier hs-var">mingwPath</span></a></span><span class="hs-special">]</span><span>
</span><span id="line-128"></span><span>                                 </span><span class="hs-glyph">|</span><span> </span><span class="annot"><span class="annottext">Bool
</span><a href="../../base/src/GHC.Base.html#otherwise"><span class="hs-identifier hs-var">otherwise</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">[String]
</span><a href="#local-6989586621679717013"><span class="hs-identifier hs-var">mbDir</span></a></span><span>
</span><span id="line-129"></span><span>      </span><span class="hs-keyword">where</span><span>
</span><span id="line-130"></span><span>        </span><span id="local-6989586621679717013"><span class="annot"><span class="annottext">mbDir :: [String]
</span><a href="#local-6989586621679717013"><span class="hs-identifier hs-var hs-var">mbDir</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Maybe String -&gt; [String]
forall a. Maybe a -&gt; [a]
</span><a href="../../base/src/Data.Maybe.html#maybeToList"><span class="hs-identifier hs-var">maybeToList</span></a></span><span> </span><span class="annot"><span class="annottext">(Maybe String -&gt; [String])
-&gt; (Maybe String -&gt; Maybe String) -&gt; Maybe String -&gt; [String]
forall b c a. (b -&gt; c) -&gt; (a -&gt; b) -&gt; a -&gt; c
</span><a href="../../base/src/GHC.Base.html#."><span class="hs-operator hs-var">.</span></a></span><span> </span><span class="annot"><span class="annottext">(String -&gt; String) -&gt; Maybe String -&gt; Maybe String
forall (f :: * -&gt; *) a b. Functor f =&gt; (a -&gt; b) -&gt; f a -&gt; f b
</span><a href="../../base/src/GHC.Base.html#fmap"><span class="hs-identifier hs-var">fmap</span></a></span><span> </span><span class="annot"><span class="annottext">String -&gt; String
</span><a href="../../filepath/src/System.FilePath.Windows.html#takeDirectory"><span class="hs-identifier hs-var">takeDirectory</span></a></span><span> </span><span class="annot"><span class="annottext">(Maybe String -&gt; [String]) -&gt; Maybe String -&gt; [String]
forall a b. (a -&gt; b) -&gt; a -&gt; b
</span><a href="../../base/src/GHC.Base.html#%24"><span class="hs-operator hs-var">$</span></a></span><span> </span><span class="annot"><span class="annottext">Maybe String
</span><a href="#local-6989586621679717015"><span class="hs-identifier hs-var">mbPath</span></a></span><span>
</span><span id="line-131"></span><span>
</span><span id="line-132"></span><span>    </span><span id="local-6989586621679717048"><span class="annot"><span class="annottext">extraGccPath :: [String]
</span><a href="#local-6989586621679717048"><span class="hs-identifier hs-var hs-var">extraGccPath</span></a></span></span><span>   </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Maybe String -&gt; String -&gt; [String]
</span><a href="#local-6989586621679717016"><span class="hs-identifier hs-var">mkExtraPath</span></a></span><span> </span><span class="annot"><span class="annottext">Maybe String
</span><a href="#local-6989586621679717020"><span class="hs-identifier hs-var">mbGccLocation</span></a></span><span>   </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679717009"><span class="hs-identifier hs-var">windowsExtraGccDir</span></a></span><span>
</span><span id="line-133"></span><span>    </span><span id="local-6989586621679717042"><span class="annot"><span class="annottext">extraLdPath :: [String]
</span><a href="#local-6989586621679717042"><span class="hs-identifier hs-var hs-var">extraLdPath</span></a></span></span><span>    </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Maybe String -&gt; String -&gt; [String]
</span><a href="#local-6989586621679717016"><span class="hs-identifier hs-var">mkExtraPath</span></a></span><span> </span><span class="annot"><span class="annottext">Maybe String
</span><a href="#local-6989586621679717019"><span class="hs-identifier hs-var">mbLdLocation</span></a></span><span>    </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679717008"><span class="hs-identifier hs-var">windowsExtraLdDir</span></a></span><span>
</span><span id="line-134"></span><span>    </span><span id="local-6989586621679717038"><span class="annot"><span class="annottext">extraArPath :: [String]
</span><a href="#local-6989586621679717038"><span class="hs-identifier hs-var hs-var">extraArPath</span></a></span></span><span>    </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Maybe String -&gt; String -&gt; [String]
</span><a href="#local-6989586621679717016"><span class="hs-identifier hs-var">mkExtraPath</span></a></span><span> </span><span class="annot"><span class="annottext">Maybe String
</span><a href="#local-6989586621679717018"><span class="hs-identifier hs-var">mbArLocation</span></a></span><span>    </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679717007"><span class="hs-identifier hs-var">windowsExtraArDir</span></a></span><span>
</span><span id="line-135"></span><span>    </span><span id="local-6989586621679717035"><span class="annot"><span class="annottext">extraStripPath :: [String]
</span><a href="#local-6989586621679717035"><span class="hs-identifier hs-var hs-var">extraStripPath</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Maybe String -&gt; String -&gt; [String]
</span><a href="#local-6989586621679717016"><span class="hs-identifier hs-var">mkExtraPath</span></a></span><span> </span><span class="annot"><span class="annottext">Maybe String
</span><a href="#local-6989586621679717017"><span class="hs-identifier hs-var">mbStripLocation</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679717006"><span class="hs-identifier hs-var">windowsExtraStripDir</span></a></span><span>
</span><span id="line-136"></span><span>
</span><span id="line-137"></span><span>    </span><span class="hs-comment">-- on Windows finding and configuring ghc's gcc &amp; binutils is a bit special</span><span>
</span><span id="line-138"></span><span>    </span><span class="hs-special">(</span><span id="local-6989586621679717009"><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679717009"><span class="hs-identifier hs-var">windowsExtraGccDir</span></a></span></span><span class="hs-special">,</span><span> </span><span id="local-6989586621679717008"><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679717008"><span class="hs-identifier hs-var">windowsExtraLdDir</span></a></span></span><span class="hs-special">,</span><span>
</span><span id="line-139"></span><span>     </span><span id="local-6989586621679717007"><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679717007"><span class="hs-identifier hs-var">windowsExtraArDir</span></a></span></span><span class="hs-special">,</span><span> </span><span id="local-6989586621679717006"><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679717006"><span class="hs-identifier hs-var">windowsExtraStripDir</span></a></span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span>
</span><span id="line-140"></span><span>          </span><span class="hs-keyword">let</span><span> </span><span id="local-6989586621679717005"><span class="annot"><span class="annottext">b :: String
</span><a href="#local-6989586621679717005"><span class="hs-identifier hs-var hs-var">b</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679717031"><span class="hs-identifier hs-var">mingwBinDir</span></a></span><span> </span><span class="annot"><span class="annottext">String -&gt; String -&gt; String
</span><a href="../../filepath/src/System.FilePath.Windows.html#%3C%2F%3E"><span class="hs-operator hs-var">&lt;/&gt;</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679717027"><span class="hs-identifier hs-var">binPrefix</span></a></span><span>
</span><span id="line-141"></span><span>          </span><span class="hs-keyword">in</span><span>  </span><span class="hs-special">(</span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679717005"><span class="hs-identifier hs-var">b</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679717005"><span class="hs-identifier hs-var">b</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679717005"><span class="hs-identifier hs-var">b</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679717005"><span class="hs-identifier hs-var">b</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-142"></span><span>
</span><span id="line-143"></span><span>    </span><span class="annot"><a href="#local-6989586621679717050"><span class="hs-identifier hs-type">findProg</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="../../base/src/GHC.Base.html#String"><span class="hs-identifier hs-type">String</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="hs-special">[</span><span class="annot"><a href="../../base/src/GHC.IO.html#FilePath"><span class="hs-identifier hs-type">FilePath</span></a></span><span class="hs-special">]</span><span>
</span><span id="line-144"></span><span>             </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="Distribution.Verbosity.html#Verbosity"><span class="hs-identifier hs-type">Verbosity</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="Distribution.Simple.Program.Find.html#ProgramSearchPath"><span class="hs-identifier hs-type">ProgramSearchPath</span></a></span><span>
</span><span id="line-145"></span><span>             </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="hs-identifier hs-type">IO</span></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="../../base/src/GHC.Maybe.html#Maybe"><span class="hs-identifier hs-type">Maybe</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="../../base/src/GHC.IO.html#FilePath"><span class="hs-identifier hs-type">FilePath</span></a></span><span class="hs-special">,</span><span> </span><span class="hs-special">[</span><span class="annot"><a href="../../base/src/GHC.IO.html#FilePath"><span class="hs-identifier hs-type">FilePath</span></a></span><span class="hs-special">]</span><span class="hs-special">)</span><span class="hs-special">)</span><span>
</span><span id="line-146"></span><span>    </span><span id="local-6989586621679717050"><span class="annot"><span class="annottext">findProg :: String
-&gt; [String]
-&gt; Verbosity
-&gt; ProgramSearchPath
-&gt; IO (Maybe (String, [String]))
</span><a href="#local-6989586621679717050"><span class="hs-identifier hs-var hs-var">findProg</span></a></span></span><span> </span><span id="local-6989586621679717004"><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679717004"><span class="hs-identifier hs-var">progName</span></a></span></span><span> </span><span id="local-6989586621679717003"><span class="annot"><span class="annottext">[String]
</span><a href="#local-6989586621679717003"><span class="hs-identifier hs-var">extraPath</span></a></span></span><span> </span><span id="local-6989586621679717002"><span class="annot"><span class="annottext">Verbosity
</span><a href="#local-6989586621679717002"><span class="hs-identifier hs-var">v</span></a></span></span><span> </span><span id="local-6989586621679717001"><span class="annot"><span class="annottext">ProgramSearchPath
</span><a href="#local-6989586621679717001"><span class="hs-identifier hs-var">searchpath</span></a></span></span><span> </span><span class="hs-glyph">=</span><span>
</span><span id="line-147"></span><span>        </span><span class="annot"><span class="annottext">Verbosity
-&gt; ProgramSearchPath -&gt; String -&gt; IO (Maybe (String, [String]))
</span><a href="Distribution.Simple.Program.Find.html#findProgramOnSearchPath"><span class="hs-identifier hs-var">findProgramOnSearchPath</span></a></span><span> </span><span class="annot"><span class="annottext">Verbosity
</span><a href="#local-6989586621679717002"><span class="hs-identifier hs-var">v</span></a></span><span> </span><span class="annot"><span class="annottext">ProgramSearchPath
</span><a href="#local-6989586621679716999"><span class="hs-identifier hs-var">searchpath'</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679717004"><span class="hs-identifier hs-var">progName</span></a></span><span>
</span><span id="line-148"></span><span>      </span><span class="hs-keyword">where</span><span>
</span><span id="line-149"></span><span>        </span><span id="local-6989586621679716999"><span class="annot"><span class="annottext">searchpath' :: ProgramSearchPath
</span><a href="#local-6989586621679716999"><span class="hs-identifier hs-var hs-var">searchpath'</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">(String -&gt; ProgramSearchPathEntry) -&gt; [String] -&gt; ProgramSearchPath
forall a b. (a -&gt; b) -&gt; [a] -&gt; [b]
</span><a href="../../base/src/GHC.Base.html#map"><span class="hs-identifier hs-var">map</span></a></span><span> </span><span class="annot"><span class="annottext">String -&gt; ProgramSearchPathEntry
</span><a href="Distribution.Simple.Program.Find.html#ProgramSearchPathDir"><span class="hs-identifier hs-var">ProgramSearchPathDir</span></a></span><span> </span><span class="annot"><span class="annottext">[String]
</span><a href="#local-6989586621679717003"><span class="hs-identifier hs-var">extraPath</span></a></span><span class="hs-special">)</span><span> </span><span class="annot"><span class="annottext">ProgramSearchPath -&gt; ProgramSearchPath -&gt; ProgramSearchPath
forall a. [a] -&gt; [a] -&gt; [a]
</span><a href="../../base/src/GHC.Base.html#%2B%2B"><span class="hs-operator hs-var">++</span></a></span><span> </span><span class="annot"><span class="annottext">ProgramSearchPath
</span><a href="#local-6989586621679717001"><span class="hs-identifier hs-var">searchpath</span></a></span><span>
</span><span id="line-150"></span><span>
</span><span id="line-151"></span><span>    </span><span class="hs-comment">-- Read tool locations from the 'ghc --info' output. Useful when</span><span>
</span><span id="line-152"></span><span>    </span><span class="hs-comment">-- cross-compiling.</span><span>
</span><span id="line-153"></span><span>    </span><span id="local-6989586621679717020"><span class="annot"><span class="annottext">mbGccLocation :: Maybe String
</span><a href="#local-6989586621679717020"><span class="hs-identifier hs-var hs-var">mbGccLocation</span></a></span></span><span>   </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; Map String String -&gt; Maybe String
forall k a. Ord k =&gt; k -&gt; Map k a -&gt; Maybe a
</span><a href="../../containers/src/Data.Map.Internal.html#lookup"><span class="hs-identifier hs-var">Map.lookup</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;C compiler command&quot;</span></span><span> </span><span class="annot"><span class="annottext">Map String String
</span><a href="#local-6989586621679717054"><span class="hs-identifier hs-var">ghcInfo</span></a></span><span>
</span><span id="line-154"></span><span>    </span><span id="local-6989586621679717019"><span class="annot"><span class="annottext">mbLdLocation :: Maybe String
</span><a href="#local-6989586621679717019"><span class="hs-identifier hs-var hs-var">mbLdLocation</span></a></span></span><span>    </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; Map String String -&gt; Maybe String
forall k a. Ord k =&gt; k -&gt; Map k a -&gt; Maybe a
</span><a href="../../containers/src/Data.Map.Internal.html#lookup"><span class="hs-identifier hs-var">Map.lookup</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;ld command&quot;</span></span><span> </span><span class="annot"><span class="annottext">Map String String
</span><a href="#local-6989586621679717054"><span class="hs-identifier hs-var">ghcInfo</span></a></span><span>
</span><span id="line-155"></span><span>    </span><span id="local-6989586621679717018"><span class="annot"><span class="annottext">mbArLocation :: Maybe String
</span><a href="#local-6989586621679717018"><span class="hs-identifier hs-var hs-var">mbArLocation</span></a></span></span><span>    </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; Map String String -&gt; Maybe String
forall k a. Ord k =&gt; k -&gt; Map k a -&gt; Maybe a
</span><a href="../../containers/src/Data.Map.Internal.html#lookup"><span class="hs-identifier hs-var">Map.lookup</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;ar command&quot;</span></span><span> </span><span class="annot"><span class="annottext">Map String String
</span><a href="#local-6989586621679717054"><span class="hs-identifier hs-var">ghcInfo</span></a></span><span>
</span><span id="line-156"></span><span>    </span><span id="local-6989586621679717017"><span class="annot"><span class="annottext">mbStripLocation :: Maybe String
</span><a href="#local-6989586621679717017"><span class="hs-identifier hs-var hs-var">mbStripLocation</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; Map String String -&gt; Maybe String
forall k a. Ord k =&gt; k -&gt; Map k a -&gt; Maybe a
</span><a href="../../containers/src/Data.Map.Internal.html#lookup"><span class="hs-identifier hs-var">Map.lookup</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;strip command&quot;</span></span><span> </span><span class="annot"><span class="annottext">Map String String
</span><a href="#local-6989586621679717054"><span class="hs-identifier hs-var">ghcInfo</span></a></span><span>
</span><span id="line-157"></span><span>
</span><span id="line-158"></span><span>    </span><span id="local-6989586621679716988"><span class="annot"><span class="annottext">ccFlags :: [String]
</span><a href="#local-6989586621679716988"><span class="hs-identifier hs-var hs-var">ccFlags</span></a></span></span><span>        </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; [String]
</span><a href="#local-6989586621679716987"><span class="hs-identifier hs-var">getFlags</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;C compiler flags&quot;</span></span><span>
</span><span id="line-159"></span><span>    </span><span class="hs-comment">-- GHC 7.8 renamed &quot;Gcc Linker flags&quot; to &quot;C compiler link flags&quot;</span><span>
</span><span id="line-160"></span><span>    </span><span class="hs-comment">-- and &quot;Ld Linker flags&quot; to &quot;ld flags&quot; (GHC #4862).</span><span>
</span><span id="line-161"></span><span>    </span><span id="local-6989586621679716986"><span class="annot"><span class="annottext">gccLinkerFlags :: [String]
</span><a href="#local-6989586621679716986"><span class="hs-identifier hs-var hs-var">gccLinkerFlags</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; [String]
</span><a href="#local-6989586621679716987"><span class="hs-identifier hs-var">getFlags</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;Gcc Linker flags&quot;</span></span><span> </span><span class="annot"><span class="annottext">[String] -&gt; [String] -&gt; [String]
forall a. [a] -&gt; [a] -&gt; [a]
</span><a href="../../base/src/GHC.Base.html#%2B%2B"><span class="hs-operator hs-var">++</span></a></span><span> </span><span class="annot"><span class="annottext">String -&gt; [String]
</span><a href="#local-6989586621679716987"><span class="hs-identifier hs-var">getFlags</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;C compiler link flags&quot;</span></span><span>
</span><span id="line-162"></span><span>    </span><span id="local-6989586621679716985"><span class="annot"><span class="annottext">ldLinkerFlags :: [String]
</span><a href="#local-6989586621679716985"><span class="hs-identifier hs-var hs-var">ldLinkerFlags</span></a></span></span><span>  </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; [String]
</span><a href="#local-6989586621679716987"><span class="hs-identifier hs-var">getFlags</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;Ld Linker flags&quot;</span></span><span> </span><span class="annot"><span class="annottext">[String] -&gt; [String] -&gt; [String]
forall a. [a] -&gt; [a] -&gt; [a]
</span><a href="../../base/src/GHC.Base.html#%2B%2B"><span class="hs-operator hs-var">++</span></a></span><span> </span><span class="annot"><span class="annottext">String -&gt; [String]
</span><a href="#local-6989586621679716987"><span class="hs-identifier hs-var">getFlags</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;ld flags&quot;</span></span><span>
</span><span id="line-163"></span><span>
</span><span id="line-164"></span><span>    </span><span class="hs-comment">-- It appears that GHC 7.6 and earlier encode the tokenized flags as a</span><span>
</span><span id="line-165"></span><span>    </span><span class="hs-comment">-- [String] in these settings whereas later versions just encode the flags as</span><span>
</span><span id="line-166"></span><span>    </span><span class="hs-comment">-- String.</span><span>
</span><span id="line-167"></span><span>    </span><span class="hs-comment">--</span><span>
</span><span id="line-168"></span><span>    </span><span class="hs-comment">-- We first try to parse as a [String] and if this fails then tokenize the</span><span>
</span><span id="line-169"></span><span>    </span><span class="hs-comment">-- flags ourself.</span><span>
</span><span id="line-170"></span><span>    </span><span class="annot"><a href="#local-6989586621679716987"><span class="hs-identifier hs-type">getFlags</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="../../base/src/GHC.Base.html#String"><span class="hs-identifier hs-type">String</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="hs-special">[</span><span class="annot"><a href="../../base/src/GHC.Base.html#String"><span class="hs-identifier hs-type">String</span></a></span><span class="hs-special">]</span><span>
</span><span id="line-171"></span><span>    </span><span id="local-6989586621679716987"><span class="annot"><span class="annottext">getFlags :: String -&gt; [String]
</span><a href="#local-6989586621679716987"><span class="hs-identifier hs-var hs-var">getFlags</span></a></span></span><span> </span><span id="local-6989586621679716984"><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716984"><span class="hs-identifier hs-var">key</span></a></span></span><span> </span><span class="hs-glyph">=</span><span>
</span><span id="line-172"></span><span>        </span><span class="hs-keyword">case</span><span> </span><span class="annot"><span class="annottext">String -&gt; Map String String -&gt; Maybe String
forall k a. Ord k =&gt; k -&gt; Map k a -&gt; Maybe a
</span><a href="../../containers/src/Data.Map.Internal.html#lookup"><span class="hs-identifier hs-var">Map.lookup</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716984"><span class="hs-identifier hs-var">key</span></a></span><span> </span><span class="annot"><span class="annottext">Map String String
</span><a href="#local-6989586621679717054"><span class="hs-identifier hs-var">ghcInfo</span></a></span><span> </span><span class="hs-keyword">of</span><span>
</span><span id="line-173"></span><span>          </span><span class="annot"><span class="annottext">Maybe String
</span><a href="../../base/src/GHC.Maybe.html#Nothing"><span class="hs-identifier hs-var">Nothing</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="hs-special">[</span><span class="hs-special">]</span><span>
</span><span id="line-174"></span><span>          </span><span class="annot"><a href="../../base/src/GHC.Maybe.html#Just"><span class="hs-identifier hs-type">Just</span></a></span><span> </span><span id="local-6989586621679716983"><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716983"><span class="hs-identifier hs-var">flags</span></a></span></span><span>
</span><span id="line-175"></span><span>            </span><span class="hs-glyph">|</span><span> </span><span class="hs-special">(</span><span id="local-6989586621679716982"><span class="annot"><span class="annottext">[String]
</span><a href="#local-6989586621679716982"><span class="hs-identifier hs-var">flags'</span></a></span></span><span class="hs-special">,</span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;&quot;</span></span><span class="hs-special">)</span><span class="annot"><span class="hs-glyph hs-type">:</span></span><span class="annot"><span class="annottext">[([String], String)]
</span><span class="hs-identifier">_</span></span><span> </span><span class="hs-glyph">&lt;-</span><span> </span><span class="annot"><span class="annottext">ReadS [String]
forall a. Read a =&gt; ReadS a
</span><a href="../../base/src/Text.Read.html#reads"><span class="hs-identifier hs-var">reads</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716983"><span class="hs-identifier hs-var">flags</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">[String]
</span><a href="#local-6989586621679716982"><span class="hs-identifier hs-var">flags'</span></a></span><span>
</span><span id="line-176"></span><span>            </span><span class="hs-glyph">|</span><span> </span><span class="annot"><span class="annottext">Bool
</span><a href="../../base/src/GHC.Base.html#otherwise"><span class="hs-identifier hs-var">otherwise</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">String -&gt; [String]
</span><a href="Distribution.Lex.html#tokenizeQuotedWords"><span class="hs-identifier hs-var">tokenizeQuotedWords</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716983"><span class="hs-identifier hs-var">flags</span></a></span><span>
</span><span id="line-177"></span><span>
</span><span id="line-178"></span><span>    </span><span class="annot"><a href="#local-6989586621679717046"><span class="hs-identifier hs-type">configureGcc</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="Distribution.Verbosity.html#Verbosity"><span class="hs-identifier hs-type">Verbosity</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="Distribution.Simple.Program.Types.html#ConfiguredProgram"><span class="hs-identifier hs-type">ConfiguredProgram</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="hs-identifier hs-type">IO</span></span><span> </span><span class="annot"><a href="Distribution.Simple.Program.Types.html#ConfiguredProgram"><span class="hs-identifier hs-type">ConfiguredProgram</span></a></span><span>
</span><span id="line-179"></span><span>    </span><span id="local-6989586621679717046"><span class="annot"><span class="annottext">configureGcc :: Verbosity -&gt; ConfiguredProgram -&gt; IO ConfiguredProgram
</span><a href="#local-6989586621679717046"><span class="hs-identifier hs-var hs-var">configureGcc</span></a></span></span><span> </span><span id="local-6989586621679716979"><span class="annot"><span class="annottext">Verbosity
</span><a href="#local-6989586621679716979"><span class="hs-identifier hs-var">_v</span></a></span></span><span> </span><span id="local-6989586621679716978"><span class="annot"><span class="annottext">ConfiguredProgram
</span><a href="#local-6989586621679716978"><span class="hs-identifier hs-var">gccProg</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="hs-keyword">do</span><span>
</span><span id="line-180"></span><span>      </span><span class="annot"><span class="annottext">ConfiguredProgram -&gt; IO ConfiguredProgram
forall (m :: * -&gt; *) a. Monad m =&gt; a -&gt; m a
</span><a href="../../base/src/GHC.Base.html#return"><span class="hs-identifier hs-var">return</span></a></span><span> </span><span class="annot"><span class="annottext">ConfiguredProgram
</span><a href="#local-6989586621679716978"><span class="hs-identifier hs-var">gccProg</span></a></span><span> </span><span class="hs-special">{</span><span>
</span><span id="line-181"></span><span>        </span><span class="annot"><span class="annottext">programDefaultArgs :: [String]
</span><a href="Distribution.Simple.Program.Types.html#programDefaultArgs"><span class="hs-identifier hs-var">programDefaultArgs</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">ConfiguredProgram -&gt; [String]
</span><a href="Distribution.Simple.Program.Types.html#programDefaultArgs"><span class="hs-identifier hs-var hs-var">programDefaultArgs</span></a></span><span> </span><span class="annot"><span class="annottext">ConfiguredProgram
</span><a href="#local-6989586621679716978"><span class="hs-identifier hs-var">gccProg</span></a></span><span>
</span><span id="line-182"></span><span>                             </span><span class="annot"><span class="annottext">[String] -&gt; [String] -&gt; [String]
forall a. [a] -&gt; [a] -&gt; [a]
</span><a href="../../base/src/GHC.Base.html#%2B%2B"><span class="hs-operator hs-var">++</span></a></span><span> </span><span class="annot"><span class="annottext">[String]
</span><a href="#local-6989586621679716988"><span class="hs-identifier hs-var">ccFlags</span></a></span><span> </span><span class="annot"><span class="annottext">[String] -&gt; [String] -&gt; [String]
forall a. [a] -&gt; [a] -&gt; [a]
</span><a href="../../base/src/GHC.Base.html#%2B%2B"><span class="hs-operator hs-var">++</span></a></span><span> </span><span class="annot"><span class="annottext">[String]
</span><a href="#local-6989586621679716986"><span class="hs-identifier hs-var">gccLinkerFlags</span></a></span><span>
</span><span id="line-183"></span><span>      </span><span class="hs-special">}</span><span>
</span><span id="line-184"></span><span>
</span><span id="line-185"></span><span>    </span><span class="annot"><a href="#local-6989586621679717041"><span class="hs-identifier hs-type">configureLd</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="Distribution.Verbosity.html#Verbosity"><span class="hs-identifier hs-type">Verbosity</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="Distribution.Simple.Program.Types.html#ConfiguredProgram"><span class="hs-identifier hs-type">ConfiguredProgram</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="hs-identifier hs-type">IO</span></span><span> </span><span class="annot"><a href="Distribution.Simple.Program.Types.html#ConfiguredProgram"><span class="hs-identifier hs-type">ConfiguredProgram</span></a></span><span>
</span><span id="line-186"></span><span>    </span><span id="local-6989586621679717041"><span class="annot"><span class="annottext">configureLd :: Verbosity -&gt; ConfiguredProgram -&gt; IO ConfiguredProgram
</span><a href="#local-6989586621679717041"><span class="hs-identifier hs-var hs-var">configureLd</span></a></span></span><span> </span><span id="local-6989586621679716976"><span class="annot"><span class="annottext">Verbosity
</span><a href="#local-6989586621679716976"><span class="hs-identifier hs-var">v</span></a></span></span><span> </span><span id="local-6989586621679716975"><span class="annot"><span class="annottext">ConfiguredProgram
</span><a href="#local-6989586621679716975"><span class="hs-identifier hs-var">ldProg</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="hs-keyword">do</span><span>
</span><span id="line-187"></span><span>      </span><span id="local-6989586621679716974"><span class="annot"><span class="annottext">ConfiguredProgram
</span><a href="#local-6989586621679716974"><span class="hs-identifier hs-var">ldProg'</span></a></span></span><span> </span><span class="hs-glyph">&lt;-</span><span> </span><span class="annot"><span class="annottext">Verbosity -&gt; ConfiguredProgram -&gt; IO ConfiguredProgram
</span><a href="#local-6989586621679716973"><span class="hs-identifier hs-var">configureLd'</span></a></span><span> </span><span class="annot"><span class="annottext">Verbosity
</span><a href="#local-6989586621679716976"><span class="hs-identifier hs-var">v</span></a></span><span> </span><span class="annot"><span class="annottext">ConfiguredProgram
</span><a href="#local-6989586621679716975"><span class="hs-identifier hs-var">ldProg</span></a></span><span>
</span><span id="line-188"></span><span>      </span><span class="annot"><span class="annottext">ConfiguredProgram -&gt; IO ConfiguredProgram
forall (m :: * -&gt; *) a. Monad m =&gt; a -&gt; m a
</span><a href="../../base/src/GHC.Base.html#return"><span class="hs-identifier hs-var">return</span></a></span><span> </span><span class="annot"><span class="annottext">ConfiguredProgram
</span><a href="#local-6989586621679716974"><span class="hs-identifier hs-var">ldProg'</span></a></span><span> </span><span class="hs-special">{</span><span>
</span><span id="line-189"></span><span>        </span><span class="annot"><span class="annottext">programDefaultArgs :: [String]
</span><a href="Distribution.Simple.Program.Types.html#programDefaultArgs"><span class="hs-identifier hs-var">programDefaultArgs</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">ConfiguredProgram -&gt; [String]
</span><a href="Distribution.Simple.Program.Types.html#programDefaultArgs"><span class="hs-identifier hs-var hs-var">programDefaultArgs</span></a></span><span> </span><span class="annot"><span class="annottext">ConfiguredProgram
</span><a href="#local-6989586621679716974"><span class="hs-identifier hs-var">ldProg'</span></a></span><span> </span><span class="annot"><span class="annottext">[String] -&gt; [String] -&gt; [String]
forall a. [a] -&gt; [a] -&gt; [a]
</span><a href="../../base/src/GHC.Base.html#%2B%2B"><span class="hs-operator hs-var">++</span></a></span><span> </span><span class="annot"><span class="annottext">[String]
</span><a href="#local-6989586621679716985"><span class="hs-identifier hs-var">ldLinkerFlags</span></a></span><span>
</span><span id="line-190"></span><span>      </span><span class="hs-special">}</span><span>
</span><span id="line-191"></span><span>
</span><span id="line-192"></span><span>    </span><span class="hs-comment">-- we need to find out if ld supports the -x flag</span><span>
</span><span id="line-193"></span><span>    </span><span class="annot"><a href="#local-6989586621679716973"><span class="hs-identifier hs-type">configureLd'</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="Distribution.Verbosity.html#Verbosity"><span class="hs-identifier hs-type">Verbosity</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="Distribution.Simple.Program.Types.html#ConfiguredProgram"><span class="hs-identifier hs-type">ConfiguredProgram</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="hs-identifier hs-type">IO</span></span><span> </span><span class="annot"><a href="Distribution.Simple.Program.Types.html#ConfiguredProgram"><span class="hs-identifier hs-type">ConfiguredProgram</span></a></span><span>
</span><span id="line-194"></span><span>    </span><span id="local-6989586621679716973"><span class="annot"><span class="annottext">configureLd' :: Verbosity -&gt; ConfiguredProgram -&gt; IO ConfiguredProgram
</span><a href="#local-6989586621679716973"><span class="hs-identifier hs-var hs-var">configureLd'</span></a></span></span><span> </span><span id="local-6989586621679716972"><span class="annot"><span class="annottext">Verbosity
</span><a href="#local-6989586621679716972"><span class="hs-identifier hs-var">verbosity</span></a></span></span><span> </span><span id="local-6989586621679716971"><span class="annot"><span class="annottext">ConfiguredProgram
</span><a href="#local-6989586621679716971"><span class="hs-identifier hs-var">ldProg</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="hs-keyword">do</span><span>
</span><span id="line-195"></span><span>      </span><span id="local-6989586621679716970"><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716970"><span class="hs-identifier hs-var">tempDir</span></a></span></span><span> </span><span class="hs-glyph">&lt;-</span><span> </span><span class="annot"><span class="annottext">IO String
</span><a href="../../directory/src/System.Directory.html#getTemporaryDirectory"><span class="hs-identifier hs-var">getTemporaryDirectory</span></a></span><span>
</span><span id="line-196"></span><span>      </span><span id="local-6989586621679716969"><span class="annot"><span class="annottext">Bool
</span><a href="#local-6989586621679716969"><span class="hs-identifier hs-var">ldx</span></a></span></span><span> </span><span class="hs-glyph">&lt;-</span><span> </span><span class="annot"><span class="annottext">String -&gt; String -&gt; (String -&gt; Handle -&gt; IO Bool) -&gt; IO Bool
forall a. String -&gt; String -&gt; (String -&gt; Handle -&gt; IO a) -&gt; IO a
</span><a href="Distribution.Simple.Utils.html#withTempFile"><span class="hs-identifier hs-var">withTempFile</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716970"><span class="hs-identifier hs-var">tempDir</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;.c&quot;</span></span><span> </span><span class="annot"><span class="annottext">((String -&gt; Handle -&gt; IO Bool) -&gt; IO Bool)
-&gt; (String -&gt; Handle -&gt; IO Bool) -&gt; IO Bool
forall a b. (a -&gt; b) -&gt; a -&gt; b
</span><a href="../../base/src/GHC.Base.html#%24"><span class="hs-operator hs-var">$</span></a></span><span> </span><span class="hs-glyph">\</span><span id="local-6989586621679716967"><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716967"><span class="hs-identifier hs-var">testcfile</span></a></span></span><span> </span><span id="local-6989586621679716966"><span class="annot"><span class="annottext">Handle
</span><a href="#local-6989586621679716966"><span class="hs-identifier hs-var">testchnd</span></a></span></span><span> </span><span class="hs-glyph">-&gt;</span><span>
</span><span id="line-197"></span><span>             </span><span class="annot"><span class="annottext">String -&gt; String -&gt; (String -&gt; Handle -&gt; IO Bool) -&gt; IO Bool
forall a. String -&gt; String -&gt; (String -&gt; Handle -&gt; IO a) -&gt; IO a
</span><a href="Distribution.Simple.Utils.html#withTempFile"><span class="hs-identifier hs-var">withTempFile</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716970"><span class="hs-identifier hs-var">tempDir</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;.o&quot;</span></span><span> </span><span class="annot"><span class="annottext">((String -&gt; Handle -&gt; IO Bool) -&gt; IO Bool)
-&gt; (String -&gt; Handle -&gt; IO Bool) -&gt; IO Bool
forall a b. (a -&gt; b) -&gt; a -&gt; b
</span><a href="../../base/src/GHC.Base.html#%24"><span class="hs-operator hs-var">$</span></a></span><span> </span><span class="hs-glyph">\</span><span id="local-6989586621679716965"><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716965"><span class="hs-identifier hs-var">testofile</span></a></span></span><span> </span><span id="local-6989586621679716964"><span class="annot"><span class="annottext">Handle
</span><a href="#local-6989586621679716964"><span class="hs-identifier hs-var">testohnd</span></a></span></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="hs-keyword">do</span><span>
</span><span id="line-198"></span><span>               </span><span class="annot"><span class="annottext">Handle -&gt; String -&gt; IO ()
</span><a href="../../base/src/GHC.IO.Handle.Text.html#hPutStrLn"><span class="hs-identifier hs-var">hPutStrLn</span></a></span><span> </span><span class="annot"><span class="annottext">Handle
</span><a href="#local-6989586621679716966"><span class="hs-identifier hs-var">testchnd</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;int foo() { return 0; }&quot;</span></span><span>
</span><span id="line-199"></span><span>               </span><span class="annot"><span class="annottext">Handle -&gt; IO ()
</span><a href="../../base/src/GHC.IO.Handle.html#hClose"><span class="hs-identifier hs-var">hClose</span></a></span><span> </span><span class="annot"><span class="annottext">Handle
</span><a href="#local-6989586621679716966"><span class="hs-identifier hs-var">testchnd</span></a></span><span class="hs-special">;</span><span> </span><span class="annot"><span class="annottext">Handle -&gt; IO ()
</span><a href="../../base/src/GHC.IO.Handle.html#hClose"><span class="hs-identifier hs-var">hClose</span></a></span><span> </span><span class="annot"><span class="annottext">Handle
</span><a href="#local-6989586621679716964"><span class="hs-identifier hs-var">testohnd</span></a></span><span>
</span><span id="line-200"></span><span>               </span><span class="annot"><span class="annottext">Verbosity -&gt; ConfiguredProgram -&gt; [String] -&gt; IO ()
</span><a href="Distribution.Simple.Program.html#runProgram"><span class="hs-identifier hs-var">runProgram</span></a></span><span> </span><span class="annot"><span class="annottext">Verbosity
</span><a href="#local-6989586621679716972"><span class="hs-identifier hs-var">verbosity</span></a></span><span> </span><span class="annot"><span class="annottext">ConfiguredProgram
</span><a href="#local-6989586621679717055"><span class="hs-identifier hs-var">ghcProg</span></a></span><span>
</span><span id="line-201"></span><span>                          </span><span class="hs-special">[</span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;-hide-all-packages&quot;</span></span><span>
</span><span id="line-202"></span><span>                          </span><span class="hs-special">,</span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;-c&quot;</span></span><span class="hs-special">,</span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716967"><span class="hs-identifier hs-var">testcfile</span></a></span><span>
</span><span id="line-203"></span><span>                          </span><span class="hs-special">,</span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;-o&quot;</span></span><span class="hs-special">,</span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716965"><span class="hs-identifier hs-var">testofile</span></a></span><span>
</span><span id="line-204"></span><span>                          </span><span class="hs-special">]</span><span>
</span><span id="line-205"></span><span>               </span><span class="annot"><span class="annottext">String -&gt; String -&gt; (String -&gt; Handle -&gt; IO Bool) -&gt; IO Bool
forall a. String -&gt; String -&gt; (String -&gt; Handle -&gt; IO a) -&gt; IO a
</span><a href="Distribution.Simple.Utils.html#withTempFile"><span class="hs-identifier hs-var">withTempFile</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716970"><span class="hs-identifier hs-var">tempDir</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;.o&quot;</span></span><span> </span><span class="annot"><span class="annottext">((String -&gt; Handle -&gt; IO Bool) -&gt; IO Bool)
-&gt; (String -&gt; Handle -&gt; IO Bool) -&gt; IO Bool
forall a b. (a -&gt; b) -&gt; a -&gt; b
</span><a href="../../base/src/GHC.Base.html#%24"><span class="hs-operator hs-var">$</span></a></span><span> </span><span class="hs-glyph">\</span><span id="local-6989586621679716962"><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716962"><span class="hs-identifier hs-var">testofile'</span></a></span></span><span> </span><span id="local-6989586621679716961"><span class="annot"><span class="annottext">Handle
</span><a href="#local-6989586621679716961"><span class="hs-identifier hs-var">testohnd'</span></a></span></span><span> </span><span class="hs-glyph">-&gt;</span><span>
</span><span id="line-206"></span><span>                 </span><span class="hs-keyword">do</span><span>
</span><span id="line-207"></span><span>                   </span><span class="annot"><span class="annottext">Handle -&gt; IO ()
</span><a href="../../base/src/GHC.IO.Handle.html#hClose"><span class="hs-identifier hs-var">hClose</span></a></span><span> </span><span class="annot"><span class="annottext">Handle
</span><a href="#local-6989586621679716961"><span class="hs-identifier hs-var">testohnd'</span></a></span><span>
</span><span id="line-208"></span><span>                   </span><span class="annot"><span class="annottext">String
</span><span class="hs-identifier">_</span></span><span> </span><span class="hs-glyph">&lt;-</span><span> </span><span class="annot"><span class="annottext">Verbosity -&gt; ConfiguredProgram -&gt; [String] -&gt; IO String
</span><a href="Distribution.Simple.Program.html#getProgramOutput"><span class="hs-identifier hs-var">getProgramOutput</span></a></span><span> </span><span class="annot"><span class="annottext">Verbosity
</span><a href="#local-6989586621679716972"><span class="hs-identifier hs-var">verbosity</span></a></span><span> </span><span class="annot"><span class="annottext">ConfiguredProgram
</span><a href="#local-6989586621679716971"><span class="hs-identifier hs-var">ldProg</span></a></span><span>
</span><span id="line-209"></span><span>                     </span><span class="hs-special">[</span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;-x&quot;</span></span><span class="hs-special">,</span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;-r&quot;</span></span><span class="hs-special">,</span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716965"><span class="hs-identifier hs-var">testofile</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;-o&quot;</span></span><span class="hs-special">,</span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716962"><span class="hs-identifier hs-var">testofile'</span></a></span><span class="hs-special">]</span><span>
</span><span id="line-210"></span><span>                   </span><span class="annot"><span class="annottext">Bool -&gt; IO Bool
forall (m :: * -&gt; *) a. Monad m =&gt; a -&gt; m a
</span><a href="../../base/src/GHC.Base.html#return"><span class="hs-identifier hs-var">return</span></a></span><span> </span><span class="annot"><span class="annottext">Bool
</span><span class="hs-identifier hs-var">True</span></span><span>
</span><span id="line-211"></span><span>                 </span><span class="annot"><span class="annottext">IO Bool -&gt; (IOException -&gt; IO Bool) -&gt; IO Bool
forall a. IO a -&gt; (IOException -&gt; IO a) -&gt; IO a
</span><a href="Distribution.Compat.Exception.html#catchIO"><span class="hs-operator hs-var">`catchIO`</span></a></span><span>   </span><span class="hs-special">(</span><span class="hs-glyph">\</span><span class="annot"><span class="annottext">IOException
</span><span class="hs-identifier">_</span></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">Bool -&gt; IO Bool
forall (m :: * -&gt; *) a. Monad m =&gt; a -&gt; m a
</span><a href="../../base/src/GHC.Base.html#return"><span class="hs-identifier hs-var">return</span></a></span><span> </span><span class="annot"><span class="annottext">Bool
</span><span class="hs-identifier hs-var">False</span></span><span class="hs-special">)</span><span>
</span><span id="line-212"></span><span>                 </span><span class="annot"><span class="annottext">IO Bool -&gt; (ExitCode -&gt; IO Bool) -&gt; IO Bool
forall a. IO a -&gt; (ExitCode -&gt; IO a) -&gt; IO a
</span><a href="Distribution.Compat.Exception.html#catchExit"><span class="hs-operator hs-var">`catchExit`</span></a></span><span> </span><span class="hs-special">(</span><span class="hs-glyph">\</span><span class="annot"><span class="annottext">ExitCode
</span><span class="hs-identifier">_</span></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">Bool -&gt; IO Bool
forall (m :: * -&gt; *) a. Monad m =&gt; a -&gt; m a
</span><a href="../../base/src/GHC.Base.html#return"><span class="hs-identifier hs-var">return</span></a></span><span> </span><span class="annot"><span class="annottext">Bool
</span><span class="hs-identifier hs-var">False</span></span><span class="hs-special">)</span><span>
</span><span id="line-213"></span><span>      </span><span class="hs-keyword">if</span><span> </span><span class="annot"><span class="annottext">Bool
</span><a href="#local-6989586621679716969"><span class="hs-identifier hs-var">ldx</span></a></span><span>
</span><span id="line-214"></span><span>        </span><span class="hs-keyword">then</span><span> </span><span class="annot"><span class="annottext">ConfiguredProgram -&gt; IO ConfiguredProgram
forall (m :: * -&gt; *) a. Monad m =&gt; a -&gt; m a
</span><a href="../../base/src/GHC.Base.html#return"><span class="hs-identifier hs-var">return</span></a></span><span> </span><span class="annot"><span class="annottext">ConfiguredProgram
</span><a href="#local-6989586621679716971"><span class="hs-identifier hs-var">ldProg</span></a></span><span> </span><span class="hs-special">{</span><span> </span><span class="annot"><span class="annottext">programDefaultArgs :: [String]
</span><a href="Distribution.Simple.Program.Types.html#programDefaultArgs"><span class="hs-identifier hs-var">programDefaultArgs</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="hs-special">[</span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;-x&quot;</span></span><span class="hs-special">]</span><span> </span><span class="hs-special">}</span><span>
</span><span id="line-215"></span><span>        </span><span class="hs-keyword">else</span><span> </span><span class="annot"><span class="annottext">ConfiguredProgram -&gt; IO ConfiguredProgram
forall (m :: * -&gt; *) a. Monad m =&gt; a -&gt; m a
</span><a href="../../base/src/GHC.Base.html#return"><span class="hs-identifier hs-var">return</span></a></span><span> </span><span class="annot"><span class="annottext">ConfiguredProgram
</span><a href="#local-6989586621679716971"><span class="hs-identifier hs-var">ldProg</span></a></span><span>
</span><span id="line-216"></span><span>
</span><span id="line-217"></span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#getLanguages"><span class="hs-identifier hs-type">getLanguages</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="Distribution.Verbosity.html#Verbosity"><span class="hs-identifier hs-type">Verbosity</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="Distribution.Simple.GHC.ImplInfo.html#GhcImplInfo"><span class="hs-identifier hs-type">GhcImplInfo</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="Distribution.Simple.Program.Types.html#ConfiguredProgram"><span class="hs-identifier hs-type">ConfiguredProgram</span></a></span><span>
</span><span id="line-218"></span><span>             </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="hs-identifier hs-type">IO</span></span><span> </span><span class="hs-special">[</span><span class="hs-special">(</span><span class="annot"><a href="Language.Haskell.Extension.html#Language"><span class="hs-identifier hs-type">Language</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><a href="../../base/src/GHC.Base.html#String"><span class="hs-identifier hs-type">String</span></a></span><span class="hs-special">)</span><span class="hs-special">]</span><span>
</span><span id="line-219"></span><span id="getLanguages"><span class="annot"><span class="annottext">getLanguages :: Verbosity
-&gt; GhcImplInfo -&gt; ConfiguredProgram -&gt; IO [(Language, String)]
</span><a href="Distribution.Simple.GHC.Internal.html#getLanguages"><span class="hs-identifier hs-var hs-var">getLanguages</span></a></span></span><span> </span><span class="annot"><span class="annottext">Verbosity
</span><span class="hs-identifier">_</span></span><span> </span><span id="local-6989586621679716957"><span class="annot"><span class="annottext">GhcImplInfo
</span><a href="#local-6989586621679716957"><span class="hs-identifier hs-var">implInfo</span></a></span></span><span> </span><span class="annot"><span class="annottext">ConfiguredProgram
</span><span class="hs-identifier">_</span></span><span>
</span><span id="line-220"></span><span>  </span><span class="hs-comment">-- TODO: should be using --supported-languages rather than hard coding</span><span>
</span><span id="line-221"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span class="annot"><span class="annottext">GhcImplInfo -&gt; Bool
</span><a href="Distribution.Simple.GHC.ImplInfo.html#supportsHaskell2010"><span class="hs-identifier hs-var hs-var">supportsHaskell2010</span></a></span><span> </span><span class="annot"><span class="annottext">GhcImplInfo
</span><a href="#local-6989586621679716957"><span class="hs-identifier hs-var">implInfo</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">[(Language, String)] -&gt; IO [(Language, String)]
forall (m :: * -&gt; *) a. Monad m =&gt; a -&gt; m a
</span><a href="../../base/src/GHC.Base.html#return"><span class="hs-identifier hs-var">return</span></a></span><span> </span><span class="hs-special">[</span><span class="hs-special">(</span><span class="annot"><span class="annottext">Language
</span><a href="Language.Haskell.Extension.html#Haskell98"><span class="hs-identifier hs-var">Haskell98</span></a></span><span class="hs-special">,</span><span>   </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;-XHaskell98&quot;</span></span><span class="hs-special">)</span><span>
</span><span id="line-222"></span><span>                                          </span><span class="hs-special">,</span><span class="hs-special">(</span><span class="annot"><span class="annottext">Language
</span><a href="Language.Haskell.Extension.html#Haskell2010"><span class="hs-identifier hs-var">Haskell2010</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;-XHaskell2010&quot;</span></span><span class="hs-special">)</span><span class="hs-special">]</span><span>
</span><span id="line-223"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span class="annot"><span class="annottext">Bool
</span><a href="../../base/src/GHC.Base.html#otherwise"><span class="hs-identifier hs-var">otherwise</span></a></span><span>                    </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">[(Language, String)] -&gt; IO [(Language, String)]
forall (m :: * -&gt; *) a. Monad m =&gt; a -&gt; m a
</span><a href="../../base/src/GHC.Base.html#return"><span class="hs-identifier hs-var">return</span></a></span><span> </span><span class="hs-special">[</span><span class="hs-special">(</span><span class="annot"><span class="annottext">Language
</span><a href="Language.Haskell.Extension.html#Haskell98"><span class="hs-identifier hs-var">Haskell98</span></a></span><span class="hs-special">,</span><span>   </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;&quot;</span></span><span class="hs-special">)</span><span class="hs-special">]</span><span>
</span><span id="line-224"></span><span>
</span><span id="line-225"></span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#getGhcInfo"><span class="hs-identifier hs-type">getGhcInfo</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="Distribution.Verbosity.html#Verbosity"><span class="hs-identifier hs-type">Verbosity</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="Distribution.Simple.GHC.ImplInfo.html#GhcImplInfo"><span class="hs-identifier hs-type">GhcImplInfo</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="Distribution.Simple.Program.Types.html#ConfiguredProgram"><span class="hs-identifier hs-type">ConfiguredProgram</span></a></span><span>
</span><span id="line-226"></span><span>           </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="hs-identifier hs-type">IO</span></span><span> </span><span class="hs-special">[</span><span class="hs-special">(</span><span class="annot"><a href="../../base/src/GHC.Base.html#String"><span class="hs-identifier hs-type">String</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><a href="../../base/src/GHC.Base.html#String"><span class="hs-identifier hs-type">String</span></a></span><span class="hs-special">)</span><span class="hs-special">]</span><span>
</span><span id="line-227"></span><span id="getGhcInfo"><span class="annot"><span class="annottext">getGhcInfo :: Verbosity
-&gt; GhcImplInfo -&gt; ConfiguredProgram -&gt; IO [(String, String)]
</span><a href="Distribution.Simple.GHC.Internal.html#getGhcInfo"><span class="hs-identifier hs-var hs-var">getGhcInfo</span></a></span></span><span> </span><span id="local-6989586621679716953"><span class="annot"><span class="annottext">Verbosity
</span><a href="#local-6989586621679716953"><span class="hs-identifier hs-var">verbosity</span></a></span></span><span> </span><span id="local-6989586621679716952"><span class="annot"><span class="annottext">GhcImplInfo
</span><a href="#local-6989586621679716952"><span class="hs-identifier hs-var">_implInfo</span></a></span></span><span> </span><span id="local-6989586621679716951"><span class="annot"><span class="annottext">ConfiguredProgram
</span><a href="#local-6989586621679716951"><span class="hs-identifier hs-var">ghcProg</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="hs-keyword">do</span><span>
</span><span id="line-228"></span><span>      </span><span id="local-6989586621679716950"><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716950"><span class="hs-identifier hs-var">xs</span></a></span></span><span> </span><span class="hs-glyph">&lt;-</span><span> </span><span class="annot"><span class="annottext">Verbosity -&gt; ConfiguredProgram -&gt; [String] -&gt; IO String
</span><a href="Distribution.Simple.Program.html#getProgramOutput"><span class="hs-identifier hs-var">getProgramOutput</span></a></span><span> </span><span class="annot"><span class="annottext">Verbosity
</span><a href="#local-6989586621679716953"><span class="hs-identifier hs-var">verbosity</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">ConfiguredProgram -&gt; ConfiguredProgram
</span><a href="Distribution.Simple.Program.Types.html#suppressOverrideArgs"><span class="hs-identifier hs-var">suppressOverrideArgs</span></a></span><span> </span><span class="annot"><span class="annottext">ConfiguredProgram
</span><a href="#local-6989586621679716951"><span class="hs-identifier hs-var">ghcProg</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-229"></span><span>                 </span><span class="hs-special">[</span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;--info&quot;</span></span><span class="hs-special">]</span><span>
</span><span id="line-230"></span><span>      </span><span class="hs-keyword">case</span><span> </span><span class="annot"><span class="annottext">ReadS [(String, String)]
forall a. Read a =&gt; ReadS a
</span><a href="../../base/src/Text.Read.html#reads"><span class="hs-identifier hs-var">reads</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716950"><span class="hs-identifier hs-var">xs</span></a></span><span> </span><span class="hs-keyword">of</span><span>
</span><span id="line-231"></span><span>        </span><span class="hs-special">[</span><span class="hs-special">(</span><span id="local-6989586621679716948"><span class="annot"><span class="annottext">[(String, String)]
</span><a href="#local-6989586621679716948"><span class="hs-identifier hs-var">i</span></a></span></span><span class="hs-special">,</span><span> </span><span id="local-6989586621679716947"><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716947"><span class="hs-identifier hs-var">ss</span></a></span></span><span class="hs-special">)</span><span class="hs-special">]</span><span>
</span><span id="line-232"></span><span>          </span><span class="hs-glyph">|</span><span> </span><span class="annot"><span class="annottext">(Char -&gt; Bool) -&gt; String -&gt; Bool
forall (t :: * -&gt; *) a. Foldable t =&gt; (a -&gt; Bool) -&gt; t a -&gt; Bool
</span><a href="../../base/src/Data.Foldable.html#all"><span class="hs-identifier hs-var">all</span></a></span><span> </span><span class="annot"><span class="annottext">Char -&gt; Bool
</span><a href="../../base/src/GHC.Unicode.html#isSpace"><span class="hs-identifier hs-var">isSpace</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716947"><span class="hs-identifier hs-var">ss</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span>
</span><span id="line-233"></span><span>              </span><span class="annot"><span class="annottext">[(String, String)] -&gt; IO [(String, String)]
forall (m :: * -&gt; *) a. Monad m =&gt; a -&gt; m a
</span><a href="../../base/src/GHC.Base.html#return"><span class="hs-identifier hs-var">return</span></a></span><span> </span><span class="annot"><span class="annottext">[(String, String)]
</span><a href="#local-6989586621679716948"><span class="hs-identifier hs-var">i</span></a></span><span>
</span><span id="line-234"></span><span>        </span><span class="annot"><span class="annottext">[([(String, String)], String)]
</span><span class="hs-identifier">_</span></span><span> </span><span class="hs-glyph">-&gt;</span><span>
</span><span id="line-235"></span><span>          </span><span class="annot"><span class="annottext">Verbosity -&gt; String -&gt; IO [(String, String)]
forall a. Verbosity -&gt; String -&gt; IO a
</span><a href="Distribution.Simple.Utils.html#die%27"><span class="hs-identifier hs-var">die'</span></a></span><span> </span><span class="annot"><span class="annottext">Verbosity
</span><a href="#local-6989586621679716953"><span class="hs-identifier hs-var">verbosity</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;Can't parse --info output of GHC&quot;</span></span><span>
</span><span id="line-236"></span><span>
</span><span id="line-237"></span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#getExtensions"><span class="hs-identifier hs-type">getExtensions</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="Distribution.Verbosity.html#Verbosity"><span class="hs-identifier hs-type">Verbosity</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="Distribution.Simple.GHC.ImplInfo.html#GhcImplInfo"><span class="hs-identifier hs-type">GhcImplInfo</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="Distribution.Simple.Program.Types.html#ConfiguredProgram"><span class="hs-identifier hs-type">ConfiguredProgram</span></a></span><span>
</span><span id="line-238"></span><span>              </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="hs-identifier hs-type">IO</span></span><span> </span><span class="hs-special">[</span><span class="hs-special">(</span><span class="annot"><a href="Language.Haskell.Extension.html#Extension"><span class="hs-identifier hs-type">Extension</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><a href="../../base/src/GHC.Maybe.html#Maybe"><span class="hs-identifier hs-type">Maybe</span></a></span><span> </span><span class="annot"><a href="../../base/src/GHC.Base.html#String"><span class="hs-identifier hs-type">String</span></a></span><span class="hs-special">)</span><span class="hs-special">]</span><span>
</span><span id="line-239"></span><span id="getExtensions"><span class="annot"><span class="annottext">getExtensions :: Verbosity
-&gt; GhcImplInfo
-&gt; ConfiguredProgram
-&gt; IO [(Extension, Maybe String)]
</span><a href="Distribution.Simple.GHC.Internal.html#getExtensions"><span class="hs-identifier hs-var hs-var">getExtensions</span></a></span></span><span> </span><span id="local-6989586621679716943"><span class="annot"><span class="annottext">Verbosity
</span><a href="#local-6989586621679716943"><span class="hs-identifier hs-var">verbosity</span></a></span></span><span> </span><span id="local-6989586621679716942"><span class="annot"><span class="annottext">GhcImplInfo
</span><a href="#local-6989586621679716942"><span class="hs-identifier hs-var">implInfo</span></a></span></span><span> </span><span id="local-6989586621679716941"><span class="annot"><span class="annottext">ConfiguredProgram
</span><a href="#local-6989586621679716941"><span class="hs-identifier hs-var">ghcProg</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="hs-keyword">do</span><span>
</span><span id="line-240"></span><span>    </span><span id="local-6989586621679716940"><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716940"><span class="hs-identifier hs-var">str</span></a></span></span><span> </span><span class="hs-glyph">&lt;-</span><span> </span><span class="annot"><span class="annottext">Verbosity -&gt; ConfiguredProgram -&gt; [String] -&gt; IO String
</span><a href="Distribution.Simple.Program.html#getProgramOutput"><span class="hs-identifier hs-var">getProgramOutput</span></a></span><span> </span><span class="annot"><span class="annottext">Verbosity
</span><a href="#local-6989586621679716943"><span class="hs-identifier hs-var">verbosity</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">ConfiguredProgram -&gt; ConfiguredProgram
</span><a href="Distribution.Simple.Program.Types.html#suppressOverrideArgs"><span class="hs-identifier hs-var">suppressOverrideArgs</span></a></span><span> </span><span class="annot"><span class="annottext">ConfiguredProgram
</span><a href="#local-6989586621679716941"><span class="hs-identifier hs-var">ghcProg</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-241"></span><span>              </span><span class="hs-special">[</span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;--supported-languages&quot;</span></span><span class="hs-special">]</span><span>
</span><span id="line-242"></span><span>    </span><span class="hs-keyword">let</span><span> </span><span id="local-6989586621679716939"><span class="annot"><span class="annottext">extStrs :: [String]
</span><a href="#local-6989586621679716939"><span class="hs-identifier hs-var hs-var">extStrs</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="hs-keyword">if</span><span> </span><span class="annot"><span class="annottext">GhcImplInfo -&gt; Bool
</span><a href="Distribution.Simple.GHC.ImplInfo.html#reportsNoExt"><span class="hs-identifier hs-var hs-var">reportsNoExt</span></a></span><span> </span><span class="annot"><span class="annottext">GhcImplInfo
</span><a href="#local-6989586621679716942"><span class="hs-identifier hs-var">implInfo</span></a></span><span>
</span><span id="line-243"></span><span>                  </span><span class="hs-keyword">then</span><span> </span><span class="annot"><span class="annottext">String -&gt; [String]
</span><a href="../../base/src/Data.OldList.html#lines"><span class="hs-identifier hs-var">lines</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716940"><span class="hs-identifier hs-var">str</span></a></span><span>
</span><span id="line-244"></span><span>                  </span><span class="hs-keyword">else</span><span> </span><span class="hs-comment">-- Older GHCs only gave us either Foo or NoFoo,</span><span>
</span><span id="line-245"></span><span>                       </span><span class="hs-comment">-- so we have to work out the other one ourselves</span><span>
</span><span id="line-246"></span><span>                       </span><span class="hs-special">[</span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716936"><span class="hs-identifier hs-var">extStr''</span></a></span><span>
</span><span id="line-247"></span><span>                       </span><span class="hs-glyph">|</span><span> </span><span id="local-6989586621679716935"><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716935"><span class="hs-identifier hs-var">extStr</span></a></span></span><span> </span><span class="hs-glyph">&lt;-</span><span> </span><span class="annot"><span class="annottext">String -&gt; [String]
</span><a href="../../base/src/Data.OldList.html#lines"><span class="hs-identifier hs-var">lines</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716940"><span class="hs-identifier hs-var">str</span></a></span><span>
</span><span id="line-248"></span><span>                       </span><span class="hs-special">,</span><span> </span><span class="hs-keyword">let</span><span> </span><span id="local-6989586621679716934"><span class="annot"><span class="annottext">extStr' :: String
</span><a href="#local-6989586621679716934"><span class="hs-identifier hs-var hs-var">extStr'</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="hs-keyword">case</span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716935"><span class="hs-identifier hs-var">extStr</span></a></span><span> </span><span class="hs-keyword">of</span><span>
</span><span id="line-249"></span><span>                                       </span><span class="annot"><span class="annottext">Char
</span><span class="hs-char">'N'</span></span><span> </span><span class="annot"><span class="hs-glyph hs-type">:</span></span><span> </span><span class="annot"><span class="annottext">Char
</span><span class="hs-char">'o'</span></span><span> </span><span class="annot"><span class="hs-glyph hs-type">:</span></span><span> </span><span id="local-6989586621679716933"><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716933"><span class="hs-identifier hs-var">xs</span></a></span></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716933"><span class="hs-identifier hs-var">xs</span></a></span><span>
</span><span id="line-250"></span><span>                                       </span><span class="annot"><span class="annottext">String
</span><span class="hs-identifier">_</span></span><span>              </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;No&quot;</span></span><span> </span><span class="annot"><span class="annottext">String -&gt; String -&gt; String
forall a. [a] -&gt; [a] -&gt; [a]
</span><a href="../../base/src/GHC.Base.html#%2B%2B"><span class="hs-operator hs-var">++</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716935"><span class="hs-identifier hs-var">extStr</span></a></span><span>
</span><span id="line-251"></span><span>                       </span><span class="hs-special">,</span><span> </span><span id="local-6989586621679716936"><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716936"><span class="hs-identifier hs-var">extStr''</span></a></span></span><span> </span><span class="hs-glyph">&lt;-</span><span> </span><span class="hs-special">[</span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716935"><span class="hs-identifier hs-var">extStr</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716934"><span class="hs-identifier hs-var">extStr'</span></a></span><span class="hs-special">]</span><span>
</span><span id="line-252"></span><span>                       </span><span class="hs-special">]</span><span>
</span><span id="line-253"></span><span>    </span><span class="hs-keyword">let</span><span> </span><span id="local-6989586621679716928"><span class="annot"><span class="annottext">extensions0 :: [(Extension, Maybe String)]
</span><a href="#local-6989586621679716928"><span class="hs-identifier hs-var hs-var">extensions0</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="hs-special">[</span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">Extension
</span><a href="#local-6989586621679716927"><span class="hs-identifier hs-var">ext</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><span class="annottext">String -&gt; Maybe String
forall a. a -&gt; Maybe a
</span><a href="../../base/src/GHC.Maybe.html#Just"><span class="hs-identifier hs-var">Just</span></a></span><span> </span><span class="annot"><span class="annottext">(String -&gt; Maybe String) -&gt; String -&gt; Maybe String
forall a b. (a -&gt; b) -&gt; a -&gt; b
</span><a href="../../base/src/GHC.Base.html#%24"><span class="hs-operator hs-var">$</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;-X&quot;</span></span><span> </span><span class="annot"><span class="annottext">String -&gt; String -&gt; String
forall a. [a] -&gt; [a] -&gt; [a]
</span><a href="../../base/src/GHC.Base.html#%2B%2B"><span class="hs-operator hs-var">++</span></a></span><span> </span><span class="annot"><span class="annottext">Extension -&gt; String
forall a. Pretty a =&gt; a -&gt; String
</span><a href="Distribution.Pretty.html#prettyShow"><span class="hs-identifier hs-var">prettyShow</span></a></span><span> </span><span class="annot"><span class="annottext">Extension
</span><a href="#local-6989586621679716927"><span class="hs-identifier hs-var">ext</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-254"></span><span>                      </span><span class="hs-glyph">|</span><span> </span><span class="annot"><a href="../../base/src/GHC.Maybe.html#Just"><span class="hs-identifier hs-type">Just</span></a></span><span> </span><span id="local-6989586621679716927"><span class="annot"><span class="annottext">Extension
</span><a href="#local-6989586621679716927"><span class="hs-identifier hs-var">ext</span></a></span></span><span> </span><span class="hs-glyph">&lt;-</span><span> </span><span class="annot"><span class="annottext">(String -&gt; Maybe Extension) -&gt; [String] -&gt; [Maybe Extension]
forall a b. (a -&gt; b) -&gt; [a] -&gt; [b]
</span><a href="../../base/src/GHC.Base.html#map"><span class="hs-identifier hs-var">map</span></a></span><span> </span><span class="annot"><span class="annottext">String -&gt; Maybe Extension
forall a. Parsec a =&gt; String -&gt; Maybe a
</span><a href="Distribution.Parsec.html#simpleParsec"><span class="hs-identifier hs-var">simpleParsec</span></a></span><span> </span><span class="annot"><span class="annottext">[String]
</span><a href="#local-6989586621679716939"><span class="hs-identifier hs-var">extStrs</span></a></span><span> </span><span class="hs-special">]</span><span>
</span><span id="line-255"></span><span>        </span><span id="local-6989586621679716926"><span class="annot"><span class="annottext">extensions1 :: [(Extension, Maybe String)]
</span><a href="#local-6989586621679716926"><span class="hs-identifier hs-var hs-var">extensions1</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="hs-keyword">if</span><span> </span><span class="annot"><span class="annottext">GhcImplInfo -&gt; Bool
</span><a href="Distribution.Simple.GHC.ImplInfo.html#alwaysNondecIndent"><span class="hs-identifier hs-var hs-var">alwaysNondecIndent</span></a></span><span> </span><span class="annot"><span class="annottext">GhcImplInfo
</span><a href="#local-6989586621679716942"><span class="hs-identifier hs-var">implInfo</span></a></span><span>
</span><span id="line-256"></span><span>                      </span><span class="hs-keyword">then</span><span> </span><span class="hs-comment">-- ghc-7.2 split NondecreasingIndentation off</span><span>
</span><span id="line-257"></span><span>                           </span><span class="hs-comment">-- into a proper extension. Before that it</span><span>
</span><span id="line-258"></span><span>                           </span><span class="hs-comment">-- was always on.</span><span>
</span><span id="line-259"></span><span>                           </span><span class="hs-comment">-- Since it was not a proper extension, it could</span><span>
</span><span id="line-260"></span><span>                           </span><span class="hs-comment">-- not be turned off, hence we omit a</span><span>
</span><span id="line-261"></span><span>                           </span><span class="hs-comment">-- DisableExtension entry here.</span><span>
</span><span id="line-262"></span><span>                           </span><span class="hs-special">(</span><span class="annot"><span class="annottext">KnownExtension -&gt; Extension
</span><a href="Language.Haskell.Extension.html#EnableExtension"><span class="hs-identifier hs-var">EnableExtension</span></a></span><span> </span><span class="annot"><span class="annottext">KnownExtension
</span><a href="Language.Haskell.Extension.html#NondecreasingIndentation"><span class="hs-identifier hs-var">NondecreasingIndentation</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><span class="annottext">Maybe String
forall a. Maybe a
</span><a href="../../base/src/GHC.Maybe.html#Nothing"><span class="hs-identifier hs-var">Nothing</span></a></span><span class="hs-special">)</span><span> </span><span class="annot"><span class="annottext">(Extension, Maybe String)
-&gt; [(Extension, Maybe String)] -&gt; [(Extension, Maybe String)]
forall a. a -&gt; [a] -&gt; [a]
</span><span class="hs-glyph hs-var">:</span></span><span>
</span><span id="line-263"></span><span>                           </span><span class="annot"><span class="annottext">[(Extension, Maybe String)]
</span><a href="#local-6989586621679716928"><span class="hs-identifier hs-var">extensions0</span></a></span><span>
</span><span id="line-264"></span><span>                      </span><span class="hs-keyword">else</span><span> </span><span class="annot"><span class="annottext">[(Extension, Maybe String)]
</span><a href="#local-6989586621679716928"><span class="hs-identifier hs-var">extensions0</span></a></span><span>
</span><span id="line-265"></span><span>    </span><span class="annot"><span class="annottext">[(Extension, Maybe String)] -&gt; IO [(Extension, Maybe String)]
forall (m :: * -&gt; *) a. Monad m =&gt; a -&gt; m a
</span><a href="../../base/src/GHC.Base.html#return"><span class="hs-identifier hs-var">return</span></a></span><span> </span><span class="annot"><span class="annottext">[(Extension, Maybe String)]
</span><a href="#local-6989586621679716926"><span class="hs-identifier hs-var">extensions1</span></a></span><span>
</span><span id="line-266"></span><span>
</span><span id="line-267"></span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#componentCcGhcOptions"><span class="hs-identifier hs-type">componentCcGhcOptions</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="Distribution.Verbosity.html#Verbosity"><span class="hs-identifier hs-type">Verbosity</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="Distribution.Simple.GHC.ImplInfo.html#GhcImplInfo"><span class="hs-identifier hs-type">GhcImplInfo</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="Distribution.Types.LocalBuildInfo.html#LocalBuildInfo"><span class="hs-identifier hs-type">LocalBuildInfo</span></a></span><span>
</span><span id="line-268"></span><span>                      </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="Distribution.Types.BuildInfo.html#BuildInfo"><span class="hs-identifier hs-type">BuildInfo</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="Distribution.Types.ComponentLocalBuildInfo.html#ComponentLocalBuildInfo"><span class="hs-identifier hs-type">ComponentLocalBuildInfo</span></a></span><span>
</span><span id="line-269"></span><span>                      </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="../../base/src/GHC.IO.html#FilePath"><span class="hs-identifier hs-type">FilePath</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="../../base/src/GHC.IO.html#FilePath"><span class="hs-identifier hs-type">FilePath</span></a></span><span>
</span><span id="line-270"></span><span>                      </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="Distribution.Simple.Program.GHC.html#GhcOptions"><span class="hs-identifier hs-type">GhcOptions</span></a></span><span>
</span><span id="line-271"></span><span id="componentCcGhcOptions"><span class="annot"><span class="annottext">componentCcGhcOptions :: Verbosity
-&gt; GhcImplInfo
-&gt; LocalBuildInfo
-&gt; BuildInfo
-&gt; ComponentLocalBuildInfo
-&gt; String
-&gt; String
-&gt; GhcOptions
</span><a href="Distribution.Simple.GHC.Internal.html#componentCcGhcOptions"><span class="hs-identifier hs-var hs-var">componentCcGhcOptions</span></a></span></span><span> </span><span id="local-6989586621679716922"><span class="annot"><span class="annottext">Verbosity
</span><a href="#local-6989586621679716922"><span class="hs-identifier hs-var">verbosity</span></a></span></span><span> </span><span id="local-6989586621679716921"><span class="annot"><span class="annottext">GhcImplInfo
</span><a href="#local-6989586621679716921"><span class="hs-identifier hs-var">_implInfo</span></a></span></span><span> </span><span id="local-6989586621679716920"><span class="annot"><span class="annottext">LocalBuildInfo
</span><a href="#local-6989586621679716920"><span class="hs-identifier hs-var">lbi</span></a></span></span><span> </span><span id="local-6989586621679716919"><span class="annot"><span class="annottext">BuildInfo
</span><a href="#local-6989586621679716919"><span class="hs-identifier hs-var">bi</span></a></span></span><span> </span><span id="local-6989586621679716918"><span class="annot"><span class="annottext">ComponentLocalBuildInfo
</span><a href="#local-6989586621679716918"><span class="hs-identifier hs-var">clbi</span></a></span></span><span> </span><span id="local-6989586621679716917"><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716917"><span class="hs-identifier hs-var">odir</span></a></span></span><span> </span><span id="local-6989586621679716916"><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716916"><span class="hs-identifier hs-var">filename</span></a></span></span><span> </span><span class="hs-glyph">=</span><span>
</span><span id="line-272"></span><span>    </span><span class="annot"><span class="annottext">GhcOptions
forall a. Monoid a =&gt; a
</span><a href="../../base/src/GHC.Base.html#mempty"><span class="hs-identifier hs-var">mempty</span></a></span><span> </span><span class="hs-special">{</span><span>
</span><span id="line-273"></span><span>      </span><span class="hs-comment">-- Respect -v0, but don't crank up verbosity on GHC if</span><span>
</span><span id="line-274"></span><span>      </span><span class="hs-comment">-- Cabal verbosity is requested. For that, use --ghc-option=-v instead!</span><span>
</span><span id="line-275"></span><span>      </span><span class="annot"><span class="annottext">ghcOptVerbosity :: Flag Verbosity
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptVerbosity"><span class="hs-identifier hs-var">ghcOptVerbosity</span></a></span><span>      </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Verbosity -&gt; Flag Verbosity
forall a. a -&gt; Flag a
</span><a href="Distribution.Simple.Flag.html#toFlag"><span class="hs-identifier hs-var">toFlag</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">Verbosity -&gt; Verbosity -&gt; Verbosity
forall a. Ord a =&gt; a -&gt; a -&gt; a
</span><span class="hs-identifier hs-var">min</span></span><span> </span><span class="annot"><span class="annottext">Verbosity
</span><a href="#local-6989586621679716922"><span class="hs-identifier hs-var">verbosity</span></a></span><span> </span><span class="annot"><span class="annottext">Verbosity
</span><a href="Distribution.Verbosity.html#normal"><span class="hs-identifier hs-var">normal</span></a></span><span class="hs-special">)</span><span class="hs-special">,</span><span>
</span><span id="line-276"></span><span>      </span><span class="annot"><span class="annottext">ghcOptMode :: Flag GhcMode
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptMode"><span class="hs-identifier hs-var">ghcOptMode</span></a></span><span>           </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">GhcMode -&gt; Flag GhcMode
forall a. a -&gt; Flag a
</span><a href="Distribution.Simple.Flag.html#toFlag"><span class="hs-identifier hs-var">toFlag</span></a></span><span> </span><span class="annot"><span class="annottext">GhcMode
</span><a href="Distribution.Simple.Program.GHC.html#GhcModeCompile"><span class="hs-identifier hs-var">GhcModeCompile</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-277"></span><span>      </span><span class="annot"><span class="annottext">ghcOptInputFiles :: NubListR String
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptInputFiles"><span class="hs-identifier hs-var">ghcOptInputFiles</span></a></span><span>     </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">[String] -&gt; NubListR String
forall a. Ord a =&gt; [a] -&gt; NubListR a
</span><a href="Distribution.Utils.NubList.html#toNubListR"><span class="hs-identifier hs-var">toNubListR</span></a></span><span> </span><span class="hs-special">[</span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716916"><span class="hs-identifier hs-var">filename</span></a></span><span class="hs-special">]</span><span class="hs-special">,</span><span>
</span><span id="line-278"></span><span>
</span><span id="line-279"></span><span>      </span><span class="annot"><span class="annottext">ghcOptCppIncludePath :: NubListR String
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptCppIncludePath"><span class="hs-identifier hs-var">ghcOptCppIncludePath</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">[String] -&gt; NubListR String
forall a. Ord a =&gt; [a] -&gt; NubListR a
</span><a href="Distribution.Utils.NubList.html#toNubListR"><span class="hs-identifier hs-var">toNubListR</span></a></span><span> </span><span class="annot"><span class="annottext">([String] -&gt; NubListR String) -&gt; [String] -&gt; NubListR String
forall a b. (a -&gt; b) -&gt; a -&gt; b
</span><a href="../../base/src/GHC.Base.html#%24"><span class="hs-operator hs-var">$</span></a></span><span> </span><span class="hs-special">[</span><span class="annot"><span class="annottext">LocalBuildInfo -&gt; ComponentLocalBuildInfo -&gt; String
</span><a href="Distribution.Simple.BuildPaths.html#autogenComponentModulesDir"><span class="hs-identifier hs-var">autogenComponentModulesDir</span></a></span><span> </span><span class="annot"><span class="annottext">LocalBuildInfo
</span><a href="#local-6989586621679716920"><span class="hs-identifier hs-var">lbi</span></a></span><span> </span><span class="annot"><span class="annottext">ComponentLocalBuildInfo
</span><a href="#local-6989586621679716918"><span class="hs-identifier hs-var">clbi</span></a></span><span>
</span><span id="line-280"></span><span>                                          </span><span class="hs-special">,</span><span class="annot"><span class="annottext">LocalBuildInfo -&gt; String
</span><a href="Distribution.Simple.BuildPaths.html#autogenPackageModulesDir"><span class="hs-identifier hs-var">autogenPackageModulesDir</span></a></span><span> </span><span class="annot"><span class="annottext">LocalBuildInfo
</span><a href="#local-6989586621679716920"><span class="hs-identifier hs-var">lbi</span></a></span><span>
</span><span id="line-281"></span><span>                                          </span><span class="hs-special">,</span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716917"><span class="hs-identifier hs-var">odir</span></a></span><span class="hs-special">]</span><span>
</span><span id="line-282"></span><span>                                          </span><span class="hs-comment">-- includes relative to the package</span><span>
</span><span id="line-283"></span><span>                                          </span><span class="annot"><span class="annottext">[String] -&gt; [String] -&gt; [String]
forall a. [a] -&gt; [a] -&gt; [a]
</span><a href="../../base/src/GHC.Base.html#%2B%2B"><span class="hs-operator hs-var">++</span></a></span><span> </span><span class="annot"><span class="annottext">BuildInfo -&gt; [String]
</span><a href="Distribution.Types.BuildInfo.html#includeDirs"><span class="hs-identifier hs-var hs-var">includeDirs</span></a></span><span> </span><span class="annot"><span class="annottext">BuildInfo
</span><a href="#local-6989586621679716919"><span class="hs-identifier hs-var">bi</span></a></span><span>
</span><span id="line-284"></span><span>                                          </span><span class="hs-comment">-- potential includes generated by `configure'</span><span>
</span><span id="line-285"></span><span>                                          </span><span class="hs-comment">-- in the build directory</span><span>
</span><span id="line-286"></span><span>                                          </span><span class="annot"><span class="annottext">[String] -&gt; [String] -&gt; [String]
forall a. [a] -&gt; [a] -&gt; [a]
</span><a href="../../base/src/GHC.Base.html#%2B%2B"><span class="hs-operator hs-var">++</span></a></span><span> </span><span class="hs-special">[</span><span class="annot"><span class="annottext">LocalBuildInfo -&gt; String
</span><a href="Distribution.Types.LocalBuildInfo.html#buildDir"><span class="hs-identifier hs-var hs-var">buildDir</span></a></span><span> </span><span class="annot"><span class="annottext">LocalBuildInfo
</span><a href="#local-6989586621679716920"><span class="hs-identifier hs-var">lbi</span></a></span><span> </span><span class="annot"><span class="annottext">String -&gt; String -&gt; String
</span><a href="../../filepath/src/System.FilePath.Windows.html#%3C%2F%3E"><span class="hs-operator hs-var">&lt;/&gt;</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716903"><span class="hs-identifier hs-var">dir</span></a></span><span> </span><span class="hs-glyph">|</span><span> </span><span id="local-6989586621679716903"><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716903"><span class="hs-identifier hs-var">dir</span></a></span></span><span> </span><span class="hs-glyph">&lt;-</span><span> </span><span class="annot"><span class="annottext">BuildInfo -&gt; [String]
</span><a href="Distribution.Types.BuildInfo.html#includeDirs"><span class="hs-identifier hs-var hs-var">includeDirs</span></a></span><span> </span><span class="annot"><span class="annottext">BuildInfo
</span><a href="#local-6989586621679716919"><span class="hs-identifier hs-var">bi</span></a></span><span class="hs-special">]</span><span class="hs-special">,</span><span>
</span><span id="line-287"></span><span>      </span><span class="annot"><span class="annottext">ghcOptHideAllPackages :: Flag Bool
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptHideAllPackages"><span class="hs-identifier hs-var">ghcOptHideAllPackages</span></a></span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Bool -&gt; Flag Bool
forall a. a -&gt; Flag a
</span><a href="Distribution.Simple.Flag.html#toFlag"><span class="hs-identifier hs-var">toFlag</span></a></span><span> </span><span class="annot"><span class="annottext">Bool
</span><span class="hs-identifier hs-var">True</span></span><span class="hs-special">,</span><span>
</span><span id="line-288"></span><span>      </span><span class="annot"><span class="annottext">ghcOptPackageDBs :: PackageDBStack
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptPackageDBs"><span class="hs-identifier hs-var">ghcOptPackageDBs</span></a></span><span>     </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">LocalBuildInfo -&gt; PackageDBStack
</span><a href="Distribution.Types.LocalBuildInfo.html#withPackageDB"><span class="hs-identifier hs-var hs-var">withPackageDB</span></a></span><span> </span><span class="annot"><span class="annottext">LocalBuildInfo
</span><a href="#local-6989586621679716920"><span class="hs-identifier hs-var">lbi</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-289"></span><span>      </span><span class="annot"><span class="annottext">ghcOptPackages :: NubListR (OpenUnitId, ModuleRenaming)
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptPackages"><span class="hs-identifier hs-var">ghcOptPackages</span></a></span><span>       </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">[(OpenUnitId, ModuleRenaming)]
-&gt; NubListR (OpenUnitId, ModuleRenaming)
forall a. Ord a =&gt; [a] -&gt; NubListR a
</span><a href="Distribution.Utils.NubList.html#toNubListR"><span class="hs-identifier hs-var">toNubListR</span></a></span><span> </span><span class="annot"><span class="annottext">([(OpenUnitId, ModuleRenaming)]
 -&gt; NubListR (OpenUnitId, ModuleRenaming))
-&gt; [(OpenUnitId, ModuleRenaming)]
-&gt; NubListR (OpenUnitId, ModuleRenaming)
forall a b. (a -&gt; b) -&gt; a -&gt; b
</span><a href="../../base/src/GHC.Base.html#%24"><span class="hs-operator hs-var">$</span></a></span><span> </span><span class="annot"><span class="annottext">ComponentLocalBuildInfo -&gt; [(OpenUnitId, ModuleRenaming)]
</span><a href="Distribution.Simple.GHC.Internal.html#mkGhcOptPackages"><span class="hs-identifier hs-var">mkGhcOptPackages</span></a></span><span> </span><span class="annot"><span class="annottext">ComponentLocalBuildInfo
</span><a href="#local-6989586621679716918"><span class="hs-identifier hs-var">clbi</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-290"></span><span>      </span><span class="annot"><span class="annottext">ghcOptCcOptions :: [String]
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptCcOptions"><span class="hs-identifier hs-var">ghcOptCcOptions</span></a></span><span>      </span><span class="hs-glyph">=</span><span> </span><span class="hs-special">(</span><span class="hs-keyword">case</span><span> </span><span class="annot"><span class="annottext">LocalBuildInfo -&gt; OptimisationLevel
</span><a href="Distribution.Types.LocalBuildInfo.html#withOptimization"><span class="hs-identifier hs-var hs-var">withOptimization</span></a></span><span> </span><span class="annot"><span class="annottext">LocalBuildInfo
</span><a href="#local-6989586621679716920"><span class="hs-identifier hs-var">lbi</span></a></span><span> </span><span class="hs-keyword">of</span><span>
</span><span id="line-291"></span><span>                                  </span><span class="annot"><span class="annottext">OptimisationLevel
</span><a href="Distribution.Simple.Compiler.html#NoOptimisation"><span class="hs-identifier hs-var">NoOptimisation</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="hs-special">[</span><span class="hs-special">]</span><span>
</span><span id="line-292"></span><span>                                  </span><span class="annot"><span class="annottext">OptimisationLevel
</span><span class="hs-identifier">_</span></span><span>              </span><span class="hs-glyph">-&gt;</span><span> </span><span class="hs-special">[</span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;-O2&quot;</span></span><span class="hs-special">]</span><span class="hs-special">)</span><span> </span><span class="annot"><span class="annottext">[String] -&gt; [String] -&gt; [String]
forall a. [a] -&gt; [a] -&gt; [a]
</span><a href="../../base/src/GHC.Base.html#%2B%2B"><span class="hs-operator hs-var">++</span></a></span><span>
</span><span id="line-293"></span><span>                             </span><span class="hs-special">(</span><span class="hs-keyword">case</span><span> </span><span class="annot"><span class="annottext">LocalBuildInfo -&gt; DebugInfoLevel
</span><a href="Distribution.Types.LocalBuildInfo.html#withDebugInfo"><span class="hs-identifier hs-var hs-var">withDebugInfo</span></a></span><span> </span><span class="annot"><span class="annottext">LocalBuildInfo
</span><a href="#local-6989586621679716920"><span class="hs-identifier hs-var">lbi</span></a></span><span> </span><span class="hs-keyword">of</span><span>
</span><span id="line-294"></span><span>                                  </span><span class="annot"><span class="annottext">DebugInfoLevel
</span><a href="Distribution.Simple.Compiler.html#NoDebugInfo"><span class="hs-identifier hs-var">NoDebugInfo</span></a></span><span>   </span><span class="hs-glyph">-&gt;</span><span> </span><span class="hs-special">[</span><span class="hs-special">]</span><span>
</span><span id="line-295"></span><span>                                  </span><span class="annot"><span class="annottext">DebugInfoLevel
</span><a href="Distribution.Simple.Compiler.html#MinimalDebugInfo"><span class="hs-identifier hs-var">MinimalDebugInfo</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="hs-special">[</span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;-g1&quot;</span></span><span class="hs-special">]</span><span>
</span><span id="line-296"></span><span>                                  </span><span class="annot"><span class="annottext">DebugInfoLevel
</span><a href="Distribution.Simple.Compiler.html#NormalDebugInfo"><span class="hs-identifier hs-var">NormalDebugInfo</span></a></span><span>  </span><span class="hs-glyph">-&gt;</span><span> </span><span class="hs-special">[</span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;-g&quot;</span></span><span class="hs-special">]</span><span>
</span><span id="line-297"></span><span>                                  </span><span class="annot"><span class="annottext">DebugInfoLevel
</span><a href="Distribution.Simple.Compiler.html#MaximalDebugInfo"><span class="hs-identifier hs-var">MaximalDebugInfo</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="hs-special">[</span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;-g3&quot;</span></span><span class="hs-special">]</span><span class="hs-special">)</span><span> </span><span class="annot"><span class="annottext">[String] -&gt; [String] -&gt; [String]
forall a. [a] -&gt; [a] -&gt; [a]
</span><a href="../../base/src/GHC.Base.html#%2B%2B"><span class="hs-operator hs-var">++</span></a></span><span>
</span><span id="line-298"></span><span>                                  </span><span class="annot"><span class="annottext">BuildInfo -&gt; [String]
</span><a href="Distribution.Types.BuildInfo.html#ccOptions"><span class="hs-identifier hs-var hs-var">ccOptions</span></a></span><span> </span><span class="annot"><span class="annottext">BuildInfo
</span><a href="#local-6989586621679716919"><span class="hs-identifier hs-var">bi</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-299"></span><span>      </span><span class="annot"><span class="annottext">ghcOptObjDir :: Flag String
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptObjDir"><span class="hs-identifier hs-var">ghcOptObjDir</span></a></span><span>         </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; Flag String
forall a. a -&gt; Flag a
</span><a href="Distribution.Simple.Flag.html#toFlag"><span class="hs-identifier hs-var">toFlag</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716917"><span class="hs-identifier hs-var">odir</span></a></span><span>
</span><span id="line-300"></span><span>    </span><span class="hs-special">}</span><span>
</span><span id="line-301"></span><span>
</span><span id="line-302"></span><span>
</span><span id="line-303"></span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#componentCxxGhcOptions"><span class="hs-identifier hs-type">componentCxxGhcOptions</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="Distribution.Verbosity.html#Verbosity"><span class="hs-identifier hs-type">Verbosity</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="Distribution.Simple.GHC.ImplInfo.html#GhcImplInfo"><span class="hs-identifier hs-type">GhcImplInfo</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="Distribution.Types.LocalBuildInfo.html#LocalBuildInfo"><span class="hs-identifier hs-type">LocalBuildInfo</span></a></span><span>
</span><span id="line-304"></span><span>                      </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="Distribution.Types.BuildInfo.html#BuildInfo"><span class="hs-identifier hs-type">BuildInfo</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="Distribution.Types.ComponentLocalBuildInfo.html#ComponentLocalBuildInfo"><span class="hs-identifier hs-type">ComponentLocalBuildInfo</span></a></span><span>
</span><span id="line-305"></span><span>                      </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="../../base/src/GHC.IO.html#FilePath"><span class="hs-identifier hs-type">FilePath</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="../../base/src/GHC.IO.html#FilePath"><span class="hs-identifier hs-type">FilePath</span></a></span><span>
</span><span id="line-306"></span><span>                      </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="Distribution.Simple.Program.GHC.html#GhcOptions"><span class="hs-identifier hs-type">GhcOptions</span></a></span><span>
</span><span id="line-307"></span><span id="componentCxxGhcOptions"><span class="annot"><span class="annottext">componentCxxGhcOptions :: Verbosity
-&gt; GhcImplInfo
-&gt; LocalBuildInfo
-&gt; BuildInfo
-&gt; ComponentLocalBuildInfo
-&gt; String
-&gt; String
-&gt; GhcOptions
</span><a href="Distribution.Simple.GHC.Internal.html#componentCxxGhcOptions"><span class="hs-identifier hs-var hs-var">componentCxxGhcOptions</span></a></span></span><span> </span><span id="local-6989586621679716888"><span class="annot"><span class="annottext">Verbosity
</span><a href="#local-6989586621679716888"><span class="hs-identifier hs-var">verbosity</span></a></span></span><span> </span><span id="local-6989586621679716887"><span class="annot"><span class="annottext">GhcImplInfo
</span><a href="#local-6989586621679716887"><span class="hs-identifier hs-var">_implInfo</span></a></span></span><span> </span><span id="local-6989586621679716886"><span class="annot"><span class="annottext">LocalBuildInfo
</span><a href="#local-6989586621679716886"><span class="hs-identifier hs-var">lbi</span></a></span></span><span> </span><span id="local-6989586621679716885"><span class="annot"><span class="annottext">BuildInfo
</span><a href="#local-6989586621679716885"><span class="hs-identifier hs-var">bi</span></a></span></span><span> </span><span id="local-6989586621679716884"><span class="annot"><span class="annottext">ComponentLocalBuildInfo
</span><a href="#local-6989586621679716884"><span class="hs-identifier hs-var">clbi</span></a></span></span><span> </span><span id="local-6989586621679716883"><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716883"><span class="hs-identifier hs-var">odir</span></a></span></span><span> </span><span id="local-6989586621679716882"><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716882"><span class="hs-identifier hs-var">filename</span></a></span></span><span> </span><span class="hs-glyph">=</span><span>
</span><span id="line-308"></span><span>    </span><span class="annot"><span class="annottext">GhcOptions
forall a. Monoid a =&gt; a
</span><a href="../../base/src/GHC.Base.html#mempty"><span class="hs-identifier hs-var">mempty</span></a></span><span> </span><span class="hs-special">{</span><span>
</span><span id="line-309"></span><span>      </span><span class="hs-comment">-- Respect -v0, but don't crank up verbosity on GHC if</span><span>
</span><span id="line-310"></span><span>      </span><span class="hs-comment">-- Cabal verbosity is requested. For that, use --ghc-option=-v instead!</span><span>
</span><span id="line-311"></span><span>      </span><span class="annot"><span class="annottext">ghcOptVerbosity :: Flag Verbosity
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptVerbosity"><span class="hs-identifier hs-var">ghcOptVerbosity</span></a></span><span>      </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Verbosity -&gt; Flag Verbosity
forall a. a -&gt; Flag a
</span><a href="Distribution.Simple.Flag.html#toFlag"><span class="hs-identifier hs-var">toFlag</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">Verbosity -&gt; Verbosity -&gt; Verbosity
forall a. Ord a =&gt; a -&gt; a -&gt; a
</span><span class="hs-identifier hs-var">min</span></span><span> </span><span class="annot"><span class="annottext">Verbosity
</span><a href="#local-6989586621679716888"><span class="hs-identifier hs-var">verbosity</span></a></span><span> </span><span class="annot"><span class="annottext">Verbosity
</span><a href="Distribution.Verbosity.html#normal"><span class="hs-identifier hs-var">normal</span></a></span><span class="hs-special">)</span><span class="hs-special">,</span><span>
</span><span id="line-312"></span><span>      </span><span class="annot"><span class="annottext">ghcOptMode :: Flag GhcMode
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptMode"><span class="hs-identifier hs-var">ghcOptMode</span></a></span><span>           </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">GhcMode -&gt; Flag GhcMode
forall a. a -&gt; Flag a
</span><a href="Distribution.Simple.Flag.html#toFlag"><span class="hs-identifier hs-var">toFlag</span></a></span><span> </span><span class="annot"><span class="annottext">GhcMode
</span><a href="Distribution.Simple.Program.GHC.html#GhcModeCompile"><span class="hs-identifier hs-var">GhcModeCompile</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-313"></span><span>      </span><span class="annot"><span class="annottext">ghcOptInputFiles :: NubListR String
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptInputFiles"><span class="hs-identifier hs-var">ghcOptInputFiles</span></a></span><span>     </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">[String] -&gt; NubListR String
forall a. Ord a =&gt; [a] -&gt; NubListR a
</span><a href="Distribution.Utils.NubList.html#toNubListR"><span class="hs-identifier hs-var">toNubListR</span></a></span><span> </span><span class="hs-special">[</span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716882"><span class="hs-identifier hs-var">filename</span></a></span><span class="hs-special">]</span><span class="hs-special">,</span><span>
</span><span id="line-314"></span><span>
</span><span id="line-315"></span><span>      </span><span class="annot"><span class="annottext">ghcOptCppIncludePath :: NubListR String
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptCppIncludePath"><span class="hs-identifier hs-var">ghcOptCppIncludePath</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">[String] -&gt; NubListR String
forall a. Ord a =&gt; [a] -&gt; NubListR a
</span><a href="Distribution.Utils.NubList.html#toNubListR"><span class="hs-identifier hs-var">toNubListR</span></a></span><span> </span><span class="annot"><span class="annottext">([String] -&gt; NubListR String) -&gt; [String] -&gt; NubListR String
forall a b. (a -&gt; b) -&gt; a -&gt; b
</span><a href="../../base/src/GHC.Base.html#%24"><span class="hs-operator hs-var">$</span></a></span><span> </span><span class="hs-special">[</span><span class="annot"><span class="annottext">LocalBuildInfo -&gt; ComponentLocalBuildInfo -&gt; String
</span><a href="Distribution.Simple.BuildPaths.html#autogenComponentModulesDir"><span class="hs-identifier hs-var">autogenComponentModulesDir</span></a></span><span> </span><span class="annot"><span class="annottext">LocalBuildInfo
</span><a href="#local-6989586621679716886"><span class="hs-identifier hs-var">lbi</span></a></span><span> </span><span class="annot"><span class="annottext">ComponentLocalBuildInfo
</span><a href="#local-6989586621679716884"><span class="hs-identifier hs-var">clbi</span></a></span><span>
</span><span id="line-316"></span><span>                                          </span><span class="hs-special">,</span><span class="annot"><span class="annottext">LocalBuildInfo -&gt; String
</span><a href="Distribution.Simple.BuildPaths.html#autogenPackageModulesDir"><span class="hs-identifier hs-var">autogenPackageModulesDir</span></a></span><span> </span><span class="annot"><span class="annottext">LocalBuildInfo
</span><a href="#local-6989586621679716886"><span class="hs-identifier hs-var">lbi</span></a></span><span>
</span><span id="line-317"></span><span>                                          </span><span class="hs-special">,</span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716883"><span class="hs-identifier hs-var">odir</span></a></span><span class="hs-special">]</span><span>
</span><span id="line-318"></span><span>                                          </span><span class="hs-comment">-- includes relative to the package</span><span>
</span><span id="line-319"></span><span>                                          </span><span class="annot"><span class="annottext">[String] -&gt; [String] -&gt; [String]
forall a. [a] -&gt; [a] -&gt; [a]
</span><a href="../../base/src/GHC.Base.html#%2B%2B"><span class="hs-operator hs-var">++</span></a></span><span> </span><span class="annot"><span class="annottext">BuildInfo -&gt; [String]
</span><a href="Distribution.Types.BuildInfo.html#includeDirs"><span class="hs-identifier hs-var hs-var">includeDirs</span></a></span><span> </span><span class="annot"><span class="annottext">BuildInfo
</span><a href="#local-6989586621679716885"><span class="hs-identifier hs-var">bi</span></a></span><span>
</span><span id="line-320"></span><span>                                          </span><span class="hs-comment">-- potential includes generated by `configure'</span><span>
</span><span id="line-321"></span><span>                                          </span><span class="hs-comment">-- in the build directory</span><span>
</span><span id="line-322"></span><span>                                          </span><span class="annot"><span class="annottext">[String] -&gt; [String] -&gt; [String]
forall a. [a] -&gt; [a] -&gt; [a]
</span><a href="../../base/src/GHC.Base.html#%2B%2B"><span class="hs-operator hs-var">++</span></a></span><span> </span><span class="hs-special">[</span><span class="annot"><span class="annottext">LocalBuildInfo -&gt; String
</span><a href="Distribution.Types.LocalBuildInfo.html#buildDir"><span class="hs-identifier hs-var hs-var">buildDir</span></a></span><span> </span><span class="annot"><span class="annottext">LocalBuildInfo
</span><a href="#local-6989586621679716886"><span class="hs-identifier hs-var">lbi</span></a></span><span> </span><span class="annot"><span class="annottext">String -&gt; String -&gt; String
</span><a href="../../filepath/src/System.FilePath.Windows.html#%3C%2F%3E"><span class="hs-operator hs-var">&lt;/&gt;</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716881"><span class="hs-identifier hs-var">dir</span></a></span><span> </span><span class="hs-glyph">|</span><span> </span><span id="local-6989586621679716881"><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716881"><span class="hs-identifier hs-var">dir</span></a></span></span><span> </span><span class="hs-glyph">&lt;-</span><span> </span><span class="annot"><span class="annottext">BuildInfo -&gt; [String]
</span><a href="Distribution.Types.BuildInfo.html#includeDirs"><span class="hs-identifier hs-var hs-var">includeDirs</span></a></span><span> </span><span class="annot"><span class="annottext">BuildInfo
</span><a href="#local-6989586621679716885"><span class="hs-identifier hs-var">bi</span></a></span><span class="hs-special">]</span><span class="hs-special">,</span><span>
</span><span id="line-323"></span><span>      </span><span class="annot"><span class="annottext">ghcOptHideAllPackages :: Flag Bool
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptHideAllPackages"><span class="hs-identifier hs-var">ghcOptHideAllPackages</span></a></span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Bool -&gt; Flag Bool
forall a. a -&gt; Flag a
</span><a href="Distribution.Simple.Flag.html#toFlag"><span class="hs-identifier hs-var">toFlag</span></a></span><span> </span><span class="annot"><span class="annottext">Bool
</span><span class="hs-identifier hs-var">True</span></span><span class="hs-special">,</span><span>
</span><span id="line-324"></span><span>      </span><span class="annot"><span class="annottext">ghcOptPackageDBs :: PackageDBStack
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptPackageDBs"><span class="hs-identifier hs-var">ghcOptPackageDBs</span></a></span><span>     </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">LocalBuildInfo -&gt; PackageDBStack
</span><a href="Distribution.Types.LocalBuildInfo.html#withPackageDB"><span class="hs-identifier hs-var hs-var">withPackageDB</span></a></span><span> </span><span class="annot"><span class="annottext">LocalBuildInfo
</span><a href="#local-6989586621679716886"><span class="hs-identifier hs-var">lbi</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-325"></span><span>      </span><span class="annot"><span class="annottext">ghcOptPackages :: NubListR (OpenUnitId, ModuleRenaming)
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptPackages"><span class="hs-identifier hs-var">ghcOptPackages</span></a></span><span>       </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">[(OpenUnitId, ModuleRenaming)]
-&gt; NubListR (OpenUnitId, ModuleRenaming)
forall a. Ord a =&gt; [a] -&gt; NubListR a
</span><a href="Distribution.Utils.NubList.html#toNubListR"><span class="hs-identifier hs-var">toNubListR</span></a></span><span> </span><span class="annot"><span class="annottext">([(OpenUnitId, ModuleRenaming)]
 -&gt; NubListR (OpenUnitId, ModuleRenaming))
-&gt; [(OpenUnitId, ModuleRenaming)]
-&gt; NubListR (OpenUnitId, ModuleRenaming)
forall a b. (a -&gt; b) -&gt; a -&gt; b
</span><a href="../../base/src/GHC.Base.html#%24"><span class="hs-operator hs-var">$</span></a></span><span> </span><span class="annot"><span class="annottext">ComponentLocalBuildInfo -&gt; [(OpenUnitId, ModuleRenaming)]
</span><a href="Distribution.Simple.GHC.Internal.html#mkGhcOptPackages"><span class="hs-identifier hs-var">mkGhcOptPackages</span></a></span><span> </span><span class="annot"><span class="annottext">ComponentLocalBuildInfo
</span><a href="#local-6989586621679716884"><span class="hs-identifier hs-var">clbi</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-326"></span><span>      </span><span class="annot"><span class="annottext">ghcOptCxxOptions :: [String]
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptCxxOptions"><span class="hs-identifier hs-var">ghcOptCxxOptions</span></a></span><span>     </span><span class="hs-glyph">=</span><span> </span><span class="hs-special">(</span><span class="hs-keyword">case</span><span> </span><span class="annot"><span class="annottext">LocalBuildInfo -&gt; OptimisationLevel
</span><a href="Distribution.Types.LocalBuildInfo.html#withOptimization"><span class="hs-identifier hs-var hs-var">withOptimization</span></a></span><span> </span><span class="annot"><span class="annottext">LocalBuildInfo
</span><a href="#local-6989586621679716886"><span class="hs-identifier hs-var">lbi</span></a></span><span> </span><span class="hs-keyword">of</span><span>
</span><span id="line-327"></span><span>                                  </span><span class="annot"><span class="annottext">OptimisationLevel
</span><a href="Distribution.Simple.Compiler.html#NoOptimisation"><span class="hs-identifier hs-var">NoOptimisation</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="hs-special">[</span><span class="hs-special">]</span><span>
</span><span id="line-328"></span><span>                                  </span><span class="annot"><span class="annottext">OptimisationLevel
</span><span class="hs-identifier">_</span></span><span>              </span><span class="hs-glyph">-&gt;</span><span> </span><span class="hs-special">[</span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;-O2&quot;</span></span><span class="hs-special">]</span><span class="hs-special">)</span><span> </span><span class="annot"><span class="annottext">[String] -&gt; [String] -&gt; [String]
forall a. [a] -&gt; [a] -&gt; [a]
</span><a href="../../base/src/GHC.Base.html#%2B%2B"><span class="hs-operator hs-var">++</span></a></span><span>
</span><span id="line-329"></span><span>                             </span><span class="hs-special">(</span><span class="hs-keyword">case</span><span> </span><span class="annot"><span class="annottext">LocalBuildInfo -&gt; DebugInfoLevel
</span><a href="Distribution.Types.LocalBuildInfo.html#withDebugInfo"><span class="hs-identifier hs-var hs-var">withDebugInfo</span></a></span><span> </span><span class="annot"><span class="annottext">LocalBuildInfo
</span><a href="#local-6989586621679716886"><span class="hs-identifier hs-var">lbi</span></a></span><span> </span><span class="hs-keyword">of</span><span>
</span><span id="line-330"></span><span>                                  </span><span class="annot"><span class="annottext">DebugInfoLevel
</span><a href="Distribution.Simple.Compiler.html#NoDebugInfo"><span class="hs-identifier hs-var">NoDebugInfo</span></a></span><span>   </span><span class="hs-glyph">-&gt;</span><span> </span><span class="hs-special">[</span><span class="hs-special">]</span><span>
</span><span id="line-331"></span><span>                                  </span><span class="annot"><span class="annottext">DebugInfoLevel
</span><a href="Distribution.Simple.Compiler.html#MinimalDebugInfo"><span class="hs-identifier hs-var">MinimalDebugInfo</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="hs-special">[</span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;-g1&quot;</span></span><span class="hs-special">]</span><span>
</span><span id="line-332"></span><span>                                  </span><span class="annot"><span class="annottext">DebugInfoLevel
</span><a href="Distribution.Simple.Compiler.html#NormalDebugInfo"><span class="hs-identifier hs-var">NormalDebugInfo</span></a></span><span>  </span><span class="hs-glyph">-&gt;</span><span> </span><span class="hs-special">[</span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;-g&quot;</span></span><span class="hs-special">]</span><span>
</span><span id="line-333"></span><span>                                  </span><span class="annot"><span class="annottext">DebugInfoLevel
</span><a href="Distribution.Simple.Compiler.html#MaximalDebugInfo"><span class="hs-identifier hs-var">MaximalDebugInfo</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="hs-special">[</span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;-g3&quot;</span></span><span class="hs-special">]</span><span class="hs-special">)</span><span> </span><span class="annot"><span class="annottext">[String] -&gt; [String] -&gt; [String]
forall a. [a] -&gt; [a] -&gt; [a]
</span><a href="../../base/src/GHC.Base.html#%2B%2B"><span class="hs-operator hs-var">++</span></a></span><span>
</span><span id="line-334"></span><span>                                  </span><span class="annot"><span class="annottext">BuildInfo -&gt; [String]
</span><a href="Distribution.Types.BuildInfo.html#cxxOptions"><span class="hs-identifier hs-var hs-var">cxxOptions</span></a></span><span> </span><span class="annot"><span class="annottext">BuildInfo
</span><a href="#local-6989586621679716885"><span class="hs-identifier hs-var">bi</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-335"></span><span>      </span><span class="annot"><span class="annottext">ghcOptObjDir :: Flag String
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptObjDir"><span class="hs-identifier hs-var">ghcOptObjDir</span></a></span><span>         </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; Flag String
forall a. a -&gt; Flag a
</span><a href="Distribution.Simple.Flag.html#toFlag"><span class="hs-identifier hs-var">toFlag</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716883"><span class="hs-identifier hs-var">odir</span></a></span><span>
</span><span id="line-336"></span><span>    </span><span class="hs-special">}</span><span>
</span><span id="line-337"></span><span>
</span><span id="line-338"></span><span>
</span><span id="line-339"></span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#componentAsmGhcOptions"><span class="hs-identifier hs-type">componentAsmGhcOptions</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="Distribution.Verbosity.html#Verbosity"><span class="hs-identifier hs-type">Verbosity</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="Distribution.Simple.GHC.ImplInfo.html#GhcImplInfo"><span class="hs-identifier hs-type">GhcImplInfo</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="Distribution.Types.LocalBuildInfo.html#LocalBuildInfo"><span class="hs-identifier hs-type">LocalBuildInfo</span></a></span><span>
</span><span id="line-340"></span><span>                      </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="Distribution.Types.BuildInfo.html#BuildInfo"><span class="hs-identifier hs-type">BuildInfo</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="Distribution.Types.ComponentLocalBuildInfo.html#ComponentLocalBuildInfo"><span class="hs-identifier hs-type">ComponentLocalBuildInfo</span></a></span><span>
</span><span id="line-341"></span><span>                      </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="../../base/src/GHC.IO.html#FilePath"><span class="hs-identifier hs-type">FilePath</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="../../base/src/GHC.IO.html#FilePath"><span class="hs-identifier hs-type">FilePath</span></a></span><span>
</span><span id="line-342"></span><span>                      </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="Distribution.Simple.Program.GHC.html#GhcOptions"><span class="hs-identifier hs-type">GhcOptions</span></a></span><span>
</span><span id="line-343"></span><span id="componentAsmGhcOptions"><span class="annot"><span class="annottext">componentAsmGhcOptions :: Verbosity
-&gt; GhcImplInfo
-&gt; LocalBuildInfo
-&gt; BuildInfo
-&gt; ComponentLocalBuildInfo
-&gt; String
-&gt; String
-&gt; GhcOptions
</span><a href="Distribution.Simple.GHC.Internal.html#componentAsmGhcOptions"><span class="hs-identifier hs-var hs-var">componentAsmGhcOptions</span></a></span></span><span> </span><span id="local-6989586621679716878"><span class="annot"><span class="annottext">Verbosity
</span><a href="#local-6989586621679716878"><span class="hs-identifier hs-var">verbosity</span></a></span></span><span> </span><span id="local-6989586621679716877"><span class="annot"><span class="annottext">GhcImplInfo
</span><a href="#local-6989586621679716877"><span class="hs-identifier hs-var">_implInfo</span></a></span></span><span> </span><span id="local-6989586621679716876"><span class="annot"><span class="annottext">LocalBuildInfo
</span><a href="#local-6989586621679716876"><span class="hs-identifier hs-var">lbi</span></a></span></span><span> </span><span id="local-6989586621679716875"><span class="annot"><span class="annottext">BuildInfo
</span><a href="#local-6989586621679716875"><span class="hs-identifier hs-var">bi</span></a></span></span><span> </span><span id="local-6989586621679716874"><span class="annot"><span class="annottext">ComponentLocalBuildInfo
</span><a href="#local-6989586621679716874"><span class="hs-identifier hs-var">clbi</span></a></span></span><span> </span><span id="local-6989586621679716873"><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716873"><span class="hs-identifier hs-var">odir</span></a></span></span><span> </span><span id="local-6989586621679716872"><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716872"><span class="hs-identifier hs-var">filename</span></a></span></span><span> </span><span class="hs-glyph">=</span><span>
</span><span id="line-344"></span><span>    </span><span class="annot"><span class="annottext">GhcOptions
forall a. Monoid a =&gt; a
</span><a href="../../base/src/GHC.Base.html#mempty"><span class="hs-identifier hs-var">mempty</span></a></span><span> </span><span class="hs-special">{</span><span>
</span><span id="line-345"></span><span>      </span><span class="hs-comment">-- Respect -v0, but don't crank up verbosity on GHC if</span><span>
</span><span id="line-346"></span><span>      </span><span class="hs-comment">-- Cabal verbosity is requested. For that, use --ghc-option=-v instead!</span><span>
</span><span id="line-347"></span><span>      </span><span class="annot"><span class="annottext">ghcOptVerbosity :: Flag Verbosity
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptVerbosity"><span class="hs-identifier hs-var">ghcOptVerbosity</span></a></span><span>      </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Verbosity -&gt; Flag Verbosity
forall a. a -&gt; Flag a
</span><a href="Distribution.Simple.Flag.html#toFlag"><span class="hs-identifier hs-var">toFlag</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">Verbosity -&gt; Verbosity -&gt; Verbosity
forall a. Ord a =&gt; a -&gt; a -&gt; a
</span><span class="hs-identifier hs-var">min</span></span><span> </span><span class="annot"><span class="annottext">Verbosity
</span><a href="#local-6989586621679716878"><span class="hs-identifier hs-var">verbosity</span></a></span><span> </span><span class="annot"><span class="annottext">Verbosity
</span><a href="Distribution.Verbosity.html#normal"><span class="hs-identifier hs-var">normal</span></a></span><span class="hs-special">)</span><span class="hs-special">,</span><span>
</span><span id="line-348"></span><span>      </span><span class="annot"><span class="annottext">ghcOptMode :: Flag GhcMode
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptMode"><span class="hs-identifier hs-var">ghcOptMode</span></a></span><span>           </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">GhcMode -&gt; Flag GhcMode
forall a. a -&gt; Flag a
</span><a href="Distribution.Simple.Flag.html#toFlag"><span class="hs-identifier hs-var">toFlag</span></a></span><span> </span><span class="annot"><span class="annottext">GhcMode
</span><a href="Distribution.Simple.Program.GHC.html#GhcModeCompile"><span class="hs-identifier hs-var">GhcModeCompile</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-349"></span><span>      </span><span class="annot"><span class="annottext">ghcOptInputFiles :: NubListR String
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptInputFiles"><span class="hs-identifier hs-var">ghcOptInputFiles</span></a></span><span>     </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">[String] -&gt; NubListR String
forall a. Ord a =&gt; [a] -&gt; NubListR a
</span><a href="Distribution.Utils.NubList.html#toNubListR"><span class="hs-identifier hs-var">toNubListR</span></a></span><span> </span><span class="hs-special">[</span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716872"><span class="hs-identifier hs-var">filename</span></a></span><span class="hs-special">]</span><span class="hs-special">,</span><span>
</span><span id="line-350"></span><span>
</span><span id="line-351"></span><span>      </span><span class="annot"><span class="annottext">ghcOptCppIncludePath :: NubListR String
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptCppIncludePath"><span class="hs-identifier hs-var">ghcOptCppIncludePath</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">[String] -&gt; NubListR String
forall a. Ord a =&gt; [a] -&gt; NubListR a
</span><a href="Distribution.Utils.NubList.html#toNubListR"><span class="hs-identifier hs-var">toNubListR</span></a></span><span> </span><span class="annot"><span class="annottext">([String] -&gt; NubListR String) -&gt; [String] -&gt; NubListR String
forall a b. (a -&gt; b) -&gt; a -&gt; b
</span><a href="../../base/src/GHC.Base.html#%24"><span class="hs-operator hs-var">$</span></a></span><span> </span><span class="hs-special">[</span><span class="annot"><span class="annottext">LocalBuildInfo -&gt; ComponentLocalBuildInfo -&gt; String
</span><a href="Distribution.Simple.BuildPaths.html#autogenComponentModulesDir"><span class="hs-identifier hs-var">autogenComponentModulesDir</span></a></span><span> </span><span class="annot"><span class="annottext">LocalBuildInfo
</span><a href="#local-6989586621679716876"><span class="hs-identifier hs-var">lbi</span></a></span><span> </span><span class="annot"><span class="annottext">ComponentLocalBuildInfo
</span><a href="#local-6989586621679716874"><span class="hs-identifier hs-var">clbi</span></a></span><span>
</span><span id="line-352"></span><span>                                          </span><span class="hs-special">,</span><span class="annot"><span class="annottext">LocalBuildInfo -&gt; String
</span><a href="Distribution.Simple.BuildPaths.html#autogenPackageModulesDir"><span class="hs-identifier hs-var">autogenPackageModulesDir</span></a></span><span> </span><span class="annot"><span class="annottext">LocalBuildInfo
</span><a href="#local-6989586621679716876"><span class="hs-identifier hs-var">lbi</span></a></span><span>
</span><span id="line-353"></span><span>                                          </span><span class="hs-special">,</span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716873"><span class="hs-identifier hs-var">odir</span></a></span><span class="hs-special">]</span><span>
</span><span id="line-354"></span><span>                                          </span><span class="hs-comment">-- includes relative to the package</span><span>
</span><span id="line-355"></span><span>                                          </span><span class="annot"><span class="annottext">[String] -&gt; [String] -&gt; [String]
forall a. [a] -&gt; [a] -&gt; [a]
</span><a href="../../base/src/GHC.Base.html#%2B%2B"><span class="hs-operator hs-var">++</span></a></span><span> </span><span class="annot"><span class="annottext">BuildInfo -&gt; [String]
</span><a href="Distribution.Types.BuildInfo.html#includeDirs"><span class="hs-identifier hs-var hs-var">includeDirs</span></a></span><span> </span><span class="annot"><span class="annottext">BuildInfo
</span><a href="#local-6989586621679716875"><span class="hs-identifier hs-var">bi</span></a></span><span>
</span><span id="line-356"></span><span>                                          </span><span class="hs-comment">-- potential includes generated by `configure'</span><span>
</span><span id="line-357"></span><span>                                          </span><span class="hs-comment">-- in the build directory</span><span>
</span><span id="line-358"></span><span>                                          </span><span class="annot"><span class="annottext">[String] -&gt; [String] -&gt; [String]
forall a. [a] -&gt; [a] -&gt; [a]
</span><a href="../../base/src/GHC.Base.html#%2B%2B"><span class="hs-operator hs-var">++</span></a></span><span> </span><span class="hs-special">[</span><span class="annot"><span class="annottext">LocalBuildInfo -&gt; String
</span><a href="Distribution.Types.LocalBuildInfo.html#buildDir"><span class="hs-identifier hs-var hs-var">buildDir</span></a></span><span> </span><span class="annot"><span class="annottext">LocalBuildInfo
</span><a href="#local-6989586621679716876"><span class="hs-identifier hs-var">lbi</span></a></span><span> </span><span class="annot"><span class="annottext">String -&gt; String -&gt; String
</span><a href="../../filepath/src/System.FilePath.Windows.html#%3C%2F%3E"><span class="hs-operator hs-var">&lt;/&gt;</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716871"><span class="hs-identifier hs-var">dir</span></a></span><span> </span><span class="hs-glyph">|</span><span> </span><span id="local-6989586621679716871"><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716871"><span class="hs-identifier hs-var">dir</span></a></span></span><span> </span><span class="hs-glyph">&lt;-</span><span> </span><span class="annot"><span class="annottext">BuildInfo -&gt; [String]
</span><a href="Distribution.Types.BuildInfo.html#includeDirs"><span class="hs-identifier hs-var hs-var">includeDirs</span></a></span><span> </span><span class="annot"><span class="annottext">BuildInfo
</span><a href="#local-6989586621679716875"><span class="hs-identifier hs-var">bi</span></a></span><span class="hs-special">]</span><span class="hs-special">,</span><span>
</span><span id="line-359"></span><span>      </span><span class="annot"><span class="annottext">ghcOptHideAllPackages :: Flag Bool
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptHideAllPackages"><span class="hs-identifier hs-var">ghcOptHideAllPackages</span></a></span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Bool -&gt; Flag Bool
forall a. a -&gt; Flag a
</span><a href="Distribution.Simple.Flag.html#toFlag"><span class="hs-identifier hs-var">toFlag</span></a></span><span> </span><span class="annot"><span class="annottext">Bool
</span><span class="hs-identifier hs-var">True</span></span><span class="hs-special">,</span><span>
</span><span id="line-360"></span><span>      </span><span class="annot"><span class="annottext">ghcOptPackageDBs :: PackageDBStack
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptPackageDBs"><span class="hs-identifier hs-var">ghcOptPackageDBs</span></a></span><span>     </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">LocalBuildInfo -&gt; PackageDBStack
</span><a href="Distribution.Types.LocalBuildInfo.html#withPackageDB"><span class="hs-identifier hs-var hs-var">withPackageDB</span></a></span><span> </span><span class="annot"><span class="annottext">LocalBuildInfo
</span><a href="#local-6989586621679716876"><span class="hs-identifier hs-var">lbi</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-361"></span><span>      </span><span class="annot"><span class="annottext">ghcOptPackages :: NubListR (OpenUnitId, ModuleRenaming)
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptPackages"><span class="hs-identifier hs-var">ghcOptPackages</span></a></span><span>       </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">[(OpenUnitId, ModuleRenaming)]
-&gt; NubListR (OpenUnitId, ModuleRenaming)
forall a. Ord a =&gt; [a] -&gt; NubListR a
</span><a href="Distribution.Utils.NubList.html#toNubListR"><span class="hs-identifier hs-var">toNubListR</span></a></span><span> </span><span class="annot"><span class="annottext">([(OpenUnitId, ModuleRenaming)]
 -&gt; NubListR (OpenUnitId, ModuleRenaming))
-&gt; [(OpenUnitId, ModuleRenaming)]
-&gt; NubListR (OpenUnitId, ModuleRenaming)
forall a b. (a -&gt; b) -&gt; a -&gt; b
</span><a href="../../base/src/GHC.Base.html#%24"><span class="hs-operator hs-var">$</span></a></span><span> </span><span class="annot"><span class="annottext">ComponentLocalBuildInfo -&gt; [(OpenUnitId, ModuleRenaming)]
</span><a href="Distribution.Simple.GHC.Internal.html#mkGhcOptPackages"><span class="hs-identifier hs-var">mkGhcOptPackages</span></a></span><span> </span><span class="annot"><span class="annottext">ComponentLocalBuildInfo
</span><a href="#local-6989586621679716874"><span class="hs-identifier hs-var">clbi</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-362"></span><span>      </span><span class="annot"><span class="annottext">ghcOptAsmOptions :: [String]
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptAsmOptions"><span class="hs-identifier hs-var">ghcOptAsmOptions</span></a></span><span>     </span><span class="hs-glyph">=</span><span> </span><span class="hs-special">(</span><span class="hs-keyword">case</span><span> </span><span class="annot"><span class="annottext">LocalBuildInfo -&gt; OptimisationLevel
</span><a href="Distribution.Types.LocalBuildInfo.html#withOptimization"><span class="hs-identifier hs-var hs-var">withOptimization</span></a></span><span> </span><span class="annot"><span class="annottext">LocalBuildInfo
</span><a href="#local-6989586621679716876"><span class="hs-identifier hs-var">lbi</span></a></span><span> </span><span class="hs-keyword">of</span><span>
</span><span id="line-363"></span><span>                                  </span><span class="annot"><span class="annottext">OptimisationLevel
</span><a href="Distribution.Simple.Compiler.html#NoOptimisation"><span class="hs-identifier hs-var">NoOptimisation</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="hs-special">[</span><span class="hs-special">]</span><span>
</span><span id="line-364"></span><span>                                  </span><span class="annot"><span class="annottext">OptimisationLevel
</span><span class="hs-identifier">_</span></span><span>              </span><span class="hs-glyph">-&gt;</span><span> </span><span class="hs-special">[</span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;-O2&quot;</span></span><span class="hs-special">]</span><span class="hs-special">)</span><span> </span><span class="annot"><span class="annottext">[String] -&gt; [String] -&gt; [String]
forall a. [a] -&gt; [a] -&gt; [a]
</span><a href="../../base/src/GHC.Base.html#%2B%2B"><span class="hs-operator hs-var">++</span></a></span><span>
</span><span id="line-365"></span><span>                             </span><span class="hs-special">(</span><span class="hs-keyword">case</span><span> </span><span class="annot"><span class="annottext">LocalBuildInfo -&gt; DebugInfoLevel
</span><a href="Distribution.Types.LocalBuildInfo.html#withDebugInfo"><span class="hs-identifier hs-var hs-var">withDebugInfo</span></a></span><span> </span><span class="annot"><span class="annottext">LocalBuildInfo
</span><a href="#local-6989586621679716876"><span class="hs-identifier hs-var">lbi</span></a></span><span> </span><span class="hs-keyword">of</span><span>
</span><span id="line-366"></span><span>                                  </span><span class="annot"><span class="annottext">DebugInfoLevel
</span><a href="Distribution.Simple.Compiler.html#NoDebugInfo"><span class="hs-identifier hs-var">NoDebugInfo</span></a></span><span>   </span><span class="hs-glyph">-&gt;</span><span> </span><span class="hs-special">[</span><span class="hs-special">]</span><span>
</span><span id="line-367"></span><span>                                  </span><span class="annot"><span class="annottext">DebugInfoLevel
</span><a href="Distribution.Simple.Compiler.html#MinimalDebugInfo"><span class="hs-identifier hs-var">MinimalDebugInfo</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="hs-special">[</span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;-g1&quot;</span></span><span class="hs-special">]</span><span>
</span><span id="line-368"></span><span>                                  </span><span class="annot"><span class="annottext">DebugInfoLevel
</span><a href="Distribution.Simple.Compiler.html#NormalDebugInfo"><span class="hs-identifier hs-var">NormalDebugInfo</span></a></span><span>  </span><span class="hs-glyph">-&gt;</span><span> </span><span class="hs-special">[</span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;-g&quot;</span></span><span class="hs-special">]</span><span>
</span><span id="line-369"></span><span>                                  </span><span class="annot"><span class="annottext">DebugInfoLevel
</span><a href="Distribution.Simple.Compiler.html#MaximalDebugInfo"><span class="hs-identifier hs-var">MaximalDebugInfo</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="hs-special">[</span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;-g3&quot;</span></span><span class="hs-special">]</span><span class="hs-special">)</span><span> </span><span class="annot"><span class="annottext">[String] -&gt; [String] -&gt; [String]
forall a. [a] -&gt; [a] -&gt; [a]
</span><a href="../../base/src/GHC.Base.html#%2B%2B"><span class="hs-operator hs-var">++</span></a></span><span>
</span><span id="line-370"></span><span>                                  </span><span class="annot"><span class="annottext">BuildInfo -&gt; [String]
</span><a href="Distribution.Types.BuildInfo.html#asmOptions"><span class="hs-identifier hs-var hs-var">asmOptions</span></a></span><span> </span><span class="annot"><span class="annottext">BuildInfo
</span><a href="#local-6989586621679716875"><span class="hs-identifier hs-var">bi</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-371"></span><span>      </span><span class="annot"><span class="annottext">ghcOptObjDir :: Flag String
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptObjDir"><span class="hs-identifier hs-var">ghcOptObjDir</span></a></span><span>         </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; Flag String
forall a. a -&gt; Flag a
</span><a href="Distribution.Simple.Flag.html#toFlag"><span class="hs-identifier hs-var">toFlag</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716873"><span class="hs-identifier hs-var">odir</span></a></span><span>
</span><span id="line-372"></span><span>    </span><span class="hs-special">}</span><span>
</span><span id="line-373"></span><span>
</span><span id="line-374"></span><span>
</span><span id="line-375"></span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#componentGhcOptions"><span class="hs-identifier hs-type">componentGhcOptions</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="Distribution.Verbosity.html#Verbosity"><span class="hs-identifier hs-type">Verbosity</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="Distribution.Simple.GHC.ImplInfo.html#GhcImplInfo"><span class="hs-identifier hs-type">GhcImplInfo</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="Distribution.Types.LocalBuildInfo.html#LocalBuildInfo"><span class="hs-identifier hs-type">LocalBuildInfo</span></a></span><span>
</span><span id="line-376"></span><span>                    </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="Distribution.Types.BuildInfo.html#BuildInfo"><span class="hs-identifier hs-type">BuildInfo</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="Distribution.Types.ComponentLocalBuildInfo.html#ComponentLocalBuildInfo"><span class="hs-identifier hs-type">ComponentLocalBuildInfo</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="../../base/src/GHC.IO.html#FilePath"><span class="hs-identifier hs-type">FilePath</span></a></span><span>
</span><span id="line-377"></span><span>                    </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="Distribution.Simple.Program.GHC.html#GhcOptions"><span class="hs-identifier hs-type">GhcOptions</span></a></span><span>
</span><span id="line-378"></span><span id="componentGhcOptions"><span class="annot"><span class="annottext">componentGhcOptions :: Verbosity
-&gt; GhcImplInfo
-&gt; LocalBuildInfo
-&gt; BuildInfo
-&gt; ComponentLocalBuildInfo
-&gt; String
-&gt; GhcOptions
</span><a href="Distribution.Simple.GHC.Internal.html#componentGhcOptions"><span class="hs-identifier hs-var hs-var">componentGhcOptions</span></a></span></span><span> </span><span id="local-6989586621679716868"><span class="annot"><span class="annottext">Verbosity
</span><a href="#local-6989586621679716868"><span class="hs-identifier hs-var">verbosity</span></a></span></span><span> </span><span id="local-6989586621679716867"><span class="annot"><span class="annottext">GhcImplInfo
</span><a href="#local-6989586621679716867"><span class="hs-identifier hs-var">implInfo</span></a></span></span><span> </span><span id="local-6989586621679716866"><span class="annot"><span class="annottext">LocalBuildInfo
</span><a href="#local-6989586621679716866"><span class="hs-identifier hs-var">lbi</span></a></span></span><span> </span><span id="local-6989586621679716865"><span class="annot"><span class="annottext">BuildInfo
</span><a href="#local-6989586621679716865"><span class="hs-identifier hs-var">bi</span></a></span></span><span> </span><span id="local-6989586621679716864"><span class="annot"><span class="annottext">ComponentLocalBuildInfo
</span><a href="#local-6989586621679716864"><span class="hs-identifier hs-var">clbi</span></a></span></span><span> </span><span id="local-6989586621679716863"><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716863"><span class="hs-identifier hs-var">odir</span></a></span></span><span> </span><span class="hs-glyph">=</span><span>
</span><span id="line-379"></span><span>    </span><span class="annot"><span class="annottext">GhcOptions
forall a. Monoid a =&gt; a
</span><a href="../../base/src/GHC.Base.html#mempty"><span class="hs-identifier hs-var">mempty</span></a></span><span> </span><span class="hs-special">{</span><span>
</span><span id="line-380"></span><span>      </span><span class="hs-comment">-- Respect -v0, but don't crank up verbosity on GHC if</span><span>
</span><span id="line-381"></span><span>      </span><span class="hs-comment">-- Cabal verbosity is requested. For that, use --ghc-option=-v instead!</span><span>
</span><span id="line-382"></span><span>      </span><span class="annot"><span class="annottext">ghcOptVerbosity :: Flag Verbosity
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptVerbosity"><span class="hs-identifier hs-var">ghcOptVerbosity</span></a></span><span>       </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Verbosity -&gt; Flag Verbosity
forall a. a -&gt; Flag a
</span><a href="Distribution.Simple.Flag.html#toFlag"><span class="hs-identifier hs-var">toFlag</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">Verbosity -&gt; Verbosity -&gt; Verbosity
forall a. Ord a =&gt; a -&gt; a -&gt; a
</span><span class="hs-identifier hs-var">min</span></span><span> </span><span class="annot"><span class="annottext">Verbosity
</span><a href="#local-6989586621679716868"><span class="hs-identifier hs-var">verbosity</span></a></span><span> </span><span class="annot"><span class="annottext">Verbosity
</span><a href="Distribution.Verbosity.html#normal"><span class="hs-identifier hs-var">normal</span></a></span><span class="hs-special">)</span><span class="hs-special">,</span><span>
</span><span id="line-383"></span><span>      </span><span class="annot"><span class="annottext">ghcOptCabal :: Flag Bool
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptCabal"><span class="hs-identifier hs-var">ghcOptCabal</span></a></span><span>           </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Bool -&gt; Flag Bool
forall a. a -&gt; Flag a
</span><a href="Distribution.Simple.Flag.html#toFlag"><span class="hs-identifier hs-var">toFlag</span></a></span><span> </span><span class="annot"><span class="annottext">Bool
</span><span class="hs-identifier hs-var">True</span></span><span class="hs-special">,</span><span>
</span><span id="line-384"></span><span>      </span><span class="annot"><span class="annottext">ghcOptThisUnitId :: Flag String
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptThisUnitId"><span class="hs-identifier hs-var">ghcOptThisUnitId</span></a></span><span>      </span><span class="hs-glyph">=</span><span> </span><span class="hs-keyword">case</span><span> </span><span class="annot"><span class="annottext">ComponentLocalBuildInfo
</span><a href="#local-6989586621679716864"><span class="hs-identifier hs-var">clbi</span></a></span><span> </span><span class="hs-keyword">of</span><span>
</span><span id="line-385"></span><span>        </span><span class="annot"><a href="Distribution.Types.ComponentLocalBuildInfo.html#LibComponentLocalBuildInfo"><span class="hs-identifier hs-type">LibComponentLocalBuildInfo</span></a></span><span> </span><span class="hs-special">{</span><span> </span><span class="annot"><span class="annottext">componentCompatPackageKey :: ComponentLocalBuildInfo -&gt; String
</span><a href="Distribution.Types.ComponentLocalBuildInfo.html#componentCompatPackageKey"><span class="hs-identifier hs-var">componentCompatPackageKey</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span id="local-6989586621679716858"><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716858"><span class="hs-identifier hs-var">pk</span></a></span></span><span> </span><span class="hs-special">}</span><span>
</span><span id="line-386"></span><span>          </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">String -&gt; Flag String
forall a. a -&gt; Flag a
</span><a href="Distribution.Simple.Flag.html#toFlag"><span class="hs-identifier hs-var">toFlag</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716858"><span class="hs-identifier hs-var">pk</span></a></span><span>
</span><span id="line-387"></span><span>        </span><span class="annot"><span class="annottext">ComponentLocalBuildInfo
</span><span class="hs-identifier">_</span></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">Flag String
forall a. Monoid a =&gt; a
</span><a href="../../base/src/GHC.Base.html#mempty"><span class="hs-identifier hs-var">mempty</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-388"></span><span>      </span><span class="annot"><span class="annottext">ghcOptThisComponentId :: Flag ComponentId
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptThisComponentId"><span class="hs-identifier hs-var">ghcOptThisComponentId</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="hs-keyword">case</span><span> </span><span class="annot"><span class="annottext">ComponentLocalBuildInfo
</span><a href="#local-6989586621679716864"><span class="hs-identifier hs-var">clbi</span></a></span><span> </span><span class="hs-keyword">of</span><span>
</span><span id="line-389"></span><span>          </span><span class="annot"><a href="Distribution.Types.ComponentLocalBuildInfo.html#LibComponentLocalBuildInfo"><span class="hs-identifier hs-type">LibComponentLocalBuildInfo</span></a></span><span> </span><span class="hs-special">{</span><span> </span><span class="annot"><span class="annottext">componentComponentId :: ComponentLocalBuildInfo -&gt; ComponentId
</span><a href="Distribution.Types.ComponentLocalBuildInfo.html#componentComponentId"><span class="hs-identifier hs-var">componentComponentId</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span id="local-6989586621679716855"><span class="annot"><span class="annottext">ComponentId
</span><a href="#local-6989586621679716855"><span class="hs-identifier hs-var">cid</span></a></span></span><span>
</span><span id="line-390"></span><span>                                     </span><span class="hs-special">,</span><span> </span><span class="annot"><span class="annottext">componentInstantiatedWith :: ComponentLocalBuildInfo -&gt; [(ModuleName, OpenModule)]
</span><a href="Distribution.Types.ComponentLocalBuildInfo.html#componentInstantiatedWith"><span class="hs-identifier hs-var">componentInstantiatedWith</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span id="local-6989586621679716853"><span class="annot"><span class="annottext">[(ModuleName, OpenModule)]
</span><a href="#local-6989586621679716853"><span class="hs-identifier hs-var">insts</span></a></span></span><span> </span><span class="hs-special">}</span><span> </span><span class="hs-glyph">-&gt;</span><span>
</span><span id="line-391"></span><span>              </span><span class="hs-keyword">if</span><span> </span><span class="annot"><span class="annottext">[(ModuleName, OpenModule)] -&gt; Bool
forall (t :: * -&gt; *) a. Foldable t =&gt; t a -&gt; Bool
</span><a href="../../base/src/Data.Foldable.html#null"><span class="hs-identifier hs-var">null</span></a></span><span> </span><span class="annot"><span class="annottext">[(ModuleName, OpenModule)]
</span><a href="#local-6989586621679716853"><span class="hs-identifier hs-var">insts</span></a></span><span>
</span><span id="line-392"></span><span>                  </span><span class="hs-keyword">then</span><span> </span><span class="annot"><span class="annottext">Flag ComponentId
forall a. Monoid a =&gt; a
</span><a href="../../base/src/GHC.Base.html#mempty"><span class="hs-identifier hs-var">mempty</span></a></span><span>
</span><span id="line-393"></span><span>                  </span><span class="hs-keyword">else</span><span> </span><span class="annot"><span class="annottext">ComponentId -&gt; Flag ComponentId
forall a. a -&gt; Flag a
</span><a href="Distribution.Simple.Flag.html#toFlag"><span class="hs-identifier hs-var">toFlag</span></a></span><span> </span><span class="annot"><span class="annottext">ComponentId
</span><a href="#local-6989586621679716855"><span class="hs-identifier hs-var">cid</span></a></span><span>
</span><span id="line-394"></span><span>          </span><span class="annot"><span class="annottext">ComponentLocalBuildInfo
</span><span class="hs-identifier">_</span></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">Flag ComponentId
forall a. Monoid a =&gt; a
</span><a href="../../base/src/GHC.Base.html#mempty"><span class="hs-identifier hs-var">mempty</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-395"></span><span>      </span><span class="annot"><span class="annottext">ghcOptInstantiatedWith :: [(ModuleName, OpenModule)]
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptInstantiatedWith"><span class="hs-identifier hs-var">ghcOptInstantiatedWith</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="hs-keyword">case</span><span> </span><span class="annot"><span class="annottext">ComponentLocalBuildInfo
</span><a href="#local-6989586621679716864"><span class="hs-identifier hs-var">clbi</span></a></span><span> </span><span class="hs-keyword">of</span><span>
</span><span id="line-396"></span><span>        </span><span class="annot"><a href="Distribution.Types.ComponentLocalBuildInfo.html#LibComponentLocalBuildInfo"><span class="hs-identifier hs-type">LibComponentLocalBuildInfo</span></a></span><span> </span><span class="hs-special">{</span><span> </span><span class="annot"><span class="annottext">componentInstantiatedWith :: ComponentLocalBuildInfo -&gt; [(ModuleName, OpenModule)]
</span><a href="Distribution.Types.ComponentLocalBuildInfo.html#componentInstantiatedWith"><span class="hs-identifier hs-var">componentInstantiatedWith</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span id="local-6989586621679716850"><span class="annot"><span class="annottext">[(ModuleName, OpenModule)]
</span><a href="#local-6989586621679716850"><span class="hs-identifier hs-var">insts</span></a></span></span><span> </span><span class="hs-special">}</span><span>
</span><span id="line-397"></span><span>          </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">[(ModuleName, OpenModule)]
</span><a href="#local-6989586621679716850"><span class="hs-identifier hs-var">insts</span></a></span><span>
</span><span id="line-398"></span><span>        </span><span class="annot"><span class="annottext">ComponentLocalBuildInfo
</span><span class="hs-identifier">_</span></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="hs-special">[</span><span class="hs-special">]</span><span class="hs-special">,</span><span>
</span><span id="line-399"></span><span>      </span><span class="annot"><span class="annottext">ghcOptNoCode :: Flag Bool
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptNoCode"><span class="hs-identifier hs-var">ghcOptNoCode</span></a></span><span>          </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Bool -&gt; Flag Bool
forall a. a -&gt; Flag a
</span><a href="Distribution.Simple.Flag.html#toFlag"><span class="hs-identifier hs-var">toFlag</span></a></span><span> </span><span class="annot"><span class="annottext">(Bool -&gt; Flag Bool) -&gt; Bool -&gt; Flag Bool
forall a b. (a -&gt; b) -&gt; a -&gt; b
</span><a href="../../base/src/GHC.Base.html#%24"><span class="hs-operator hs-var">$</span></a></span><span> </span><span class="annot"><span class="annottext">ComponentLocalBuildInfo -&gt; Bool
</span><a href="Distribution.Types.ComponentLocalBuildInfo.html#componentIsIndefinite"><span class="hs-identifier hs-var">componentIsIndefinite</span></a></span><span> </span><span class="annot"><span class="annottext">ComponentLocalBuildInfo
</span><a href="#local-6989586621679716864"><span class="hs-identifier hs-var">clbi</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-400"></span><span>      </span><span class="annot"><span class="annottext">ghcOptHideAllPackages :: Flag Bool
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptHideAllPackages"><span class="hs-identifier hs-var">ghcOptHideAllPackages</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Bool -&gt; Flag Bool
forall a. a -&gt; Flag a
</span><a href="Distribution.Simple.Flag.html#toFlag"><span class="hs-identifier hs-var">toFlag</span></a></span><span> </span><span class="annot"><span class="annottext">Bool
</span><span class="hs-identifier hs-var">True</span></span><span class="hs-special">,</span><span>
</span><span id="line-401"></span><span>      </span><span class="annot"><span class="annottext">ghcOptWarnMissingHomeModules :: Flag Bool
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptWarnMissingHomeModules"><span class="hs-identifier hs-var">ghcOptWarnMissingHomeModules</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Bool -&gt; Flag Bool
forall a. a -&gt; Flag a
</span><a href="Distribution.Simple.Flag.html#toFlag"><span class="hs-identifier hs-var">toFlag</span></a></span><span> </span><span class="annot"><span class="annottext">(Bool -&gt; Flag Bool) -&gt; Bool -&gt; Flag Bool
forall a b. (a -&gt; b) -&gt; a -&gt; b
</span><a href="../../base/src/GHC.Base.html#%24"><span class="hs-operator hs-var">$</span></a></span><span> </span><span class="annot"><span class="annottext">GhcImplInfo -&gt; Bool
</span><a href="Distribution.Simple.GHC.ImplInfo.html#flagWarnMissingHomeModules"><span class="hs-identifier hs-var hs-var">flagWarnMissingHomeModules</span></a></span><span> </span><span class="annot"><span class="annottext">GhcImplInfo
</span><a href="#local-6989586621679716867"><span class="hs-identifier hs-var">implInfo</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-402"></span><span>      </span><span class="annot"><span class="annottext">ghcOptPackageDBs :: PackageDBStack
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptPackageDBs"><span class="hs-identifier hs-var">ghcOptPackageDBs</span></a></span><span>      </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">LocalBuildInfo -&gt; PackageDBStack
</span><a href="Distribution.Types.LocalBuildInfo.html#withPackageDB"><span class="hs-identifier hs-var hs-var">withPackageDB</span></a></span><span> </span><span class="annot"><span class="annottext">LocalBuildInfo
</span><a href="#local-6989586621679716866"><span class="hs-identifier hs-var">lbi</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-403"></span><span>      </span><span class="annot"><span class="annottext">ghcOptPackages :: NubListR (OpenUnitId, ModuleRenaming)
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptPackages"><span class="hs-identifier hs-var">ghcOptPackages</span></a></span><span>        </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">[(OpenUnitId, ModuleRenaming)]
-&gt; NubListR (OpenUnitId, ModuleRenaming)
forall a. Ord a =&gt; [a] -&gt; NubListR a
</span><a href="Distribution.Utils.NubList.html#toNubListR"><span class="hs-identifier hs-var">toNubListR</span></a></span><span> </span><span class="annot"><span class="annottext">([(OpenUnitId, ModuleRenaming)]
 -&gt; NubListR (OpenUnitId, ModuleRenaming))
-&gt; [(OpenUnitId, ModuleRenaming)]
-&gt; NubListR (OpenUnitId, ModuleRenaming)
forall a b. (a -&gt; b) -&gt; a -&gt; b
</span><a href="../../base/src/GHC.Base.html#%24"><span class="hs-operator hs-var">$</span></a></span><span> </span><span class="annot"><span class="annottext">ComponentLocalBuildInfo -&gt; [(OpenUnitId, ModuleRenaming)]
</span><a href="Distribution.Simple.GHC.Internal.html#mkGhcOptPackages"><span class="hs-identifier hs-var">mkGhcOptPackages</span></a></span><span> </span><span class="annot"><span class="annottext">ComponentLocalBuildInfo
</span><a href="#local-6989586621679716864"><span class="hs-identifier hs-var">clbi</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-404"></span><span>      </span><span class="annot"><span class="annottext">ghcOptSplitSections :: Flag Bool
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptSplitSections"><span class="hs-identifier hs-var">ghcOptSplitSections</span></a></span><span>   </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Bool -&gt; Flag Bool
forall a. a -&gt; Flag a
</span><a href="Distribution.Simple.Flag.html#toFlag"><span class="hs-identifier hs-var">toFlag</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">LocalBuildInfo -&gt; Bool
</span><a href="Distribution.Types.LocalBuildInfo.html#splitSections"><span class="hs-identifier hs-var hs-var">splitSections</span></a></span><span> </span><span class="annot"><span class="annottext">LocalBuildInfo
</span><a href="#local-6989586621679716866"><span class="hs-identifier hs-var">lbi</span></a></span><span class="hs-special">)</span><span class="hs-special">,</span><span>
</span><span id="line-405"></span><span>      </span><span class="annot"><span class="annottext">ghcOptSplitObjs :: Flag Bool
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptSplitObjs"><span class="hs-identifier hs-var">ghcOptSplitObjs</span></a></span><span>       </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Bool -&gt; Flag Bool
forall a. a -&gt; Flag a
</span><a href="Distribution.Simple.Flag.html#toFlag"><span class="hs-identifier hs-var">toFlag</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">LocalBuildInfo -&gt; Bool
</span><a href="Distribution.Types.LocalBuildInfo.html#splitObjs"><span class="hs-identifier hs-var hs-var">splitObjs</span></a></span><span> </span><span class="annot"><span class="annottext">LocalBuildInfo
</span><a href="#local-6989586621679716866"><span class="hs-identifier hs-var">lbi</span></a></span><span class="hs-special">)</span><span class="hs-special">,</span><span>
</span><span id="line-406"></span><span>      </span><span class="annot"><span class="annottext">ghcOptSourcePathClear :: Flag Bool
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptSourcePathClear"><span class="hs-identifier hs-var">ghcOptSourcePathClear</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Bool -&gt; Flag Bool
forall a. a -&gt; Flag a
</span><a href="Distribution.Simple.Flag.html#toFlag"><span class="hs-identifier hs-var">toFlag</span></a></span><span> </span><span class="annot"><span class="annottext">Bool
</span><span class="hs-identifier hs-var">True</span></span><span class="hs-special">,</span><span>
</span><span id="line-407"></span><span>      </span><span class="annot"><span class="annottext">ghcOptSourcePath :: NubListR String
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptSourcePath"><span class="hs-identifier hs-var">ghcOptSourcePath</span></a></span><span>      </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">[String] -&gt; NubListR String
forall a. Ord a =&gt; [a] -&gt; NubListR a
</span><a href="Distribution.Utils.NubList.html#toNubListR"><span class="hs-identifier hs-var">toNubListR</span></a></span><span> </span><span class="annot"><span class="annottext">([String] -&gt; NubListR String) -&gt; [String] -&gt; NubListR String
forall a b. (a -&gt; b) -&gt; a -&gt; b
</span><a href="../../base/src/GHC.Base.html#%24"><span class="hs-operator hs-var">$</span></a></span><span> </span><span class="hs-special">[</span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716863"><span class="hs-identifier hs-var">odir</span></a></span><span class="hs-special">]</span><span> </span><span class="annot"><span class="annottext">[String] -&gt; [String] -&gt; [String]
forall a. [a] -&gt; [a] -&gt; [a]
</span><a href="../../base/src/GHC.Base.html#%2B%2B"><span class="hs-operator hs-var">++</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">BuildInfo -&gt; [String]
</span><a href="Distribution.Types.BuildInfo.html#hsSourceDirs"><span class="hs-identifier hs-var hs-var">hsSourceDirs</span></a></span><span> </span><span class="annot"><span class="annottext">BuildInfo
</span><a href="#local-6989586621679716865"><span class="hs-identifier hs-var">bi</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-408"></span><span>                                           </span><span class="annot"><span class="annottext">[String] -&gt; [String] -&gt; [String]
forall a. [a] -&gt; [a] -&gt; [a]
</span><a href="../../base/src/GHC.Base.html#%2B%2B"><span class="hs-operator hs-var">++</span></a></span><span> </span><span class="hs-special">[</span><span class="annot"><span class="annottext">LocalBuildInfo -&gt; ComponentLocalBuildInfo -&gt; String
</span><a href="Distribution.Simple.BuildPaths.html#autogenComponentModulesDir"><span class="hs-identifier hs-var">autogenComponentModulesDir</span></a></span><span> </span><span class="annot"><span class="annottext">LocalBuildInfo
</span><a href="#local-6989586621679716866"><span class="hs-identifier hs-var">lbi</span></a></span><span> </span><span class="annot"><span class="annottext">ComponentLocalBuildInfo
</span><a href="#local-6989586621679716864"><span class="hs-identifier hs-var">clbi</span></a></span><span class="hs-special">]</span><span>
</span><span id="line-409"></span><span>                                           </span><span class="annot"><span class="annottext">[String] -&gt; [String] -&gt; [String]
forall a. [a] -&gt; [a] -&gt; [a]
</span><a href="../../base/src/GHC.Base.html#%2B%2B"><span class="hs-operator hs-var">++</span></a></span><span> </span><span class="hs-special">[</span><span class="annot"><span class="annottext">LocalBuildInfo -&gt; String
</span><a href="Distribution.Simple.BuildPaths.html#autogenPackageModulesDir"><span class="hs-identifier hs-var">autogenPackageModulesDir</span></a></span><span> </span><span class="annot"><span class="annottext">LocalBuildInfo
</span><a href="#local-6989586621679716866"><span class="hs-identifier hs-var">lbi</span></a></span><span class="hs-special">]</span><span class="hs-special">,</span><span>
</span><span id="line-410"></span><span>      </span><span class="annot"><span class="annottext">ghcOptCppIncludePath :: NubListR String
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptCppIncludePath"><span class="hs-identifier hs-var">ghcOptCppIncludePath</span></a></span><span>  </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">[String] -&gt; NubListR String
forall a. Ord a =&gt; [a] -&gt; NubListR a
</span><a href="Distribution.Utils.NubList.html#toNubListR"><span class="hs-identifier hs-var">toNubListR</span></a></span><span> </span><span class="annot"><span class="annottext">([String] -&gt; NubListR String) -&gt; [String] -&gt; NubListR String
forall a b. (a -&gt; b) -&gt; a -&gt; b
</span><a href="../../base/src/GHC.Base.html#%24"><span class="hs-operator hs-var">$</span></a></span><span> </span><span class="hs-special">[</span><span class="annot"><span class="annottext">LocalBuildInfo -&gt; ComponentLocalBuildInfo -&gt; String
</span><a href="Distribution.Simple.BuildPaths.html#autogenComponentModulesDir"><span class="hs-identifier hs-var">autogenComponentModulesDir</span></a></span><span> </span><span class="annot"><span class="annottext">LocalBuildInfo
</span><a href="#local-6989586621679716866"><span class="hs-identifier hs-var">lbi</span></a></span><span> </span><span class="annot"><span class="annottext">ComponentLocalBuildInfo
</span><a href="#local-6989586621679716864"><span class="hs-identifier hs-var">clbi</span></a></span><span>
</span><span id="line-411"></span><span>                                           </span><span class="hs-special">,</span><span class="annot"><span class="annottext">LocalBuildInfo -&gt; String
</span><a href="Distribution.Simple.BuildPaths.html#autogenPackageModulesDir"><span class="hs-identifier hs-var">autogenPackageModulesDir</span></a></span><span> </span><span class="annot"><span class="annottext">LocalBuildInfo
</span><a href="#local-6989586621679716866"><span class="hs-identifier hs-var">lbi</span></a></span><span>
</span><span id="line-412"></span><span>                                           </span><span class="hs-special">,</span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716863"><span class="hs-identifier hs-var">odir</span></a></span><span class="hs-special">]</span><span>
</span><span id="line-413"></span><span>                                           </span><span class="hs-comment">-- includes relative to the package</span><span>
</span><span id="line-414"></span><span>                                           </span><span class="annot"><span class="annottext">[String] -&gt; [String] -&gt; [String]
forall a. [a] -&gt; [a] -&gt; [a]
</span><a href="../../base/src/GHC.Base.html#%2B%2B"><span class="hs-operator hs-var">++</span></a></span><span> </span><span class="annot"><span class="annottext">BuildInfo -&gt; [String]
</span><a href="Distribution.Types.BuildInfo.html#includeDirs"><span class="hs-identifier hs-var hs-var">includeDirs</span></a></span><span> </span><span class="annot"><span class="annottext">BuildInfo
</span><a href="#local-6989586621679716865"><span class="hs-identifier hs-var">bi</span></a></span><span>
</span><span id="line-415"></span><span>                                           </span><span class="hs-comment">-- potential includes generated by `configure'</span><span>
</span><span id="line-416"></span><span>                                           </span><span class="hs-comment">-- in the build directory</span><span>
</span><span id="line-417"></span><span>                                           </span><span class="annot"><span class="annottext">[String] -&gt; [String] -&gt; [String]
forall a. [a] -&gt; [a] -&gt; [a]
</span><a href="../../base/src/GHC.Base.html#%2B%2B"><span class="hs-operator hs-var">++</span></a></span><span> </span><span class="hs-special">[</span><span class="annot"><span class="annottext">LocalBuildInfo -&gt; String
</span><a href="Distribution.Types.LocalBuildInfo.html#buildDir"><span class="hs-identifier hs-var hs-var">buildDir</span></a></span><span> </span><span class="annot"><span class="annottext">LocalBuildInfo
</span><a href="#local-6989586621679716866"><span class="hs-identifier hs-var">lbi</span></a></span><span> </span><span class="annot"><span class="annottext">String -&gt; String -&gt; String
</span><a href="../../filepath/src/System.FilePath.Windows.html#%3C%2F%3E"><span class="hs-operator hs-var">&lt;/&gt;</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716838"><span class="hs-identifier hs-var">dir</span></a></span><span> </span><span class="hs-glyph">|</span><span> </span><span id="local-6989586621679716838"><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716838"><span class="hs-identifier hs-var">dir</span></a></span></span><span> </span><span class="hs-glyph">&lt;-</span><span> </span><span class="annot"><span class="annottext">BuildInfo -&gt; [String]
</span><a href="Distribution.Types.BuildInfo.html#includeDirs"><span class="hs-identifier hs-var hs-var">includeDirs</span></a></span><span> </span><span class="annot"><span class="annottext">BuildInfo
</span><a href="#local-6989586621679716865"><span class="hs-identifier hs-var">bi</span></a></span><span class="hs-special">]</span><span class="hs-special">,</span><span>
</span><span id="line-418"></span><span>      </span><span class="annot"><span class="annottext">ghcOptCppOptions :: [String]
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptCppOptions"><span class="hs-identifier hs-var">ghcOptCppOptions</span></a></span><span>      </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">BuildInfo -&gt; [String]
</span><a href="Distribution.Types.BuildInfo.html#cppOptions"><span class="hs-identifier hs-var hs-var">cppOptions</span></a></span><span> </span><span class="annot"><span class="annottext">BuildInfo
</span><a href="#local-6989586621679716865"><span class="hs-identifier hs-var">bi</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-419"></span><span>      </span><span class="annot"><span class="annottext">ghcOptCppIncludes :: NubListR String
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptCppIncludes"><span class="hs-identifier hs-var">ghcOptCppIncludes</span></a></span><span>     </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">[String] -&gt; NubListR String
forall a. Ord a =&gt; [a] -&gt; NubListR a
</span><a href="Distribution.Utils.NubList.html#toNubListR"><span class="hs-identifier hs-var">toNubListR</span></a></span><span> </span><span class="annot"><span class="annottext">([String] -&gt; NubListR String) -&gt; [String] -&gt; NubListR String
forall a b. (a -&gt; b) -&gt; a -&gt; b
</span><a href="../../base/src/GHC.Base.html#%24"><span class="hs-operator hs-var">$</span></a></span><span>
</span><span id="line-420"></span><span>                              </span><span class="hs-special">[</span><span class="annot"><span class="annottext">LocalBuildInfo -&gt; ComponentLocalBuildInfo -&gt; String
</span><a href="Distribution.Simple.BuildPaths.html#autogenComponentModulesDir"><span class="hs-identifier hs-var">autogenComponentModulesDir</span></a></span><span> </span><span class="annot"><span class="annottext">LocalBuildInfo
</span><a href="#local-6989586621679716866"><span class="hs-identifier hs-var">lbi</span></a></span><span> </span><span class="annot"><span class="annottext">ComponentLocalBuildInfo
</span><a href="#local-6989586621679716864"><span class="hs-identifier hs-var">clbi</span></a></span><span> </span><span class="annot"><span class="annottext">String -&gt; String -&gt; String
</span><a href="../../filepath/src/System.FilePath.Windows.html#%3C%2F%3E"><span class="hs-operator hs-var">&lt;/&gt;</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><a href="Distribution.Simple.BuildPaths.html#cppHeaderName"><span class="hs-identifier hs-var">cppHeaderName</span></a></span><span class="hs-special">]</span><span class="hs-special">,</span><span>
</span><span id="line-421"></span><span>      </span><span class="annot"><span class="annottext">ghcOptFfiIncludes :: NubListR String
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptFfiIncludes"><span class="hs-identifier hs-var">ghcOptFfiIncludes</span></a></span><span>     </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">[String] -&gt; NubListR String
forall a. Ord a =&gt; [a] -&gt; NubListR a
</span><a href="Distribution.Utils.NubList.html#toNubListR"><span class="hs-identifier hs-var">toNubListR</span></a></span><span> </span><span class="annot"><span class="annottext">([String] -&gt; NubListR String) -&gt; [String] -&gt; NubListR String
forall a b. (a -&gt; b) -&gt; a -&gt; b
</span><a href="../../base/src/GHC.Base.html#%24"><span class="hs-operator hs-var">$</span></a></span><span> </span><span class="annot"><span class="annottext">BuildInfo -&gt; [String]
</span><a href="Distribution.Types.BuildInfo.html#includes"><span class="hs-identifier hs-var hs-var">includes</span></a></span><span> </span><span class="annot"><span class="annottext">BuildInfo
</span><a href="#local-6989586621679716865"><span class="hs-identifier hs-var">bi</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-422"></span><span>      </span><span class="annot"><span class="annottext">ghcOptObjDir :: Flag String
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptObjDir"><span class="hs-identifier hs-var">ghcOptObjDir</span></a></span><span>          </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; Flag String
forall a. a -&gt; Flag a
</span><a href="Distribution.Simple.Flag.html#toFlag"><span class="hs-identifier hs-var">toFlag</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716863"><span class="hs-identifier hs-var">odir</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-423"></span><span>      </span><span class="annot"><span class="annottext">ghcOptHiDir :: Flag String
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptHiDir"><span class="hs-identifier hs-var">ghcOptHiDir</span></a></span><span>           </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; Flag String
forall a. a -&gt; Flag a
</span><a href="Distribution.Simple.Flag.html#toFlag"><span class="hs-identifier hs-var">toFlag</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716863"><span class="hs-identifier hs-var">odir</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-424"></span><span>      </span><span class="annot"><span class="annottext">ghcOptStubDir :: Flag String
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptStubDir"><span class="hs-identifier hs-var">ghcOptStubDir</span></a></span><span>         </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; Flag String
forall a. a -&gt; Flag a
</span><a href="Distribution.Simple.Flag.html#toFlag"><span class="hs-identifier hs-var">toFlag</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716863"><span class="hs-identifier hs-var">odir</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-425"></span><span>      </span><span class="annot"><span class="annottext">ghcOptOutputDir :: Flag String
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptOutputDir"><span class="hs-identifier hs-var">ghcOptOutputDir</span></a></span><span>       </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; Flag String
forall a. a -&gt; Flag a
</span><a href="Distribution.Simple.Flag.html#toFlag"><span class="hs-identifier hs-var">toFlag</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716863"><span class="hs-identifier hs-var">odir</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-426"></span><span>      </span><span class="annot"><span class="annottext">ghcOptOptimisation :: Flag GhcOptimisation
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptOptimisation"><span class="hs-identifier hs-var">ghcOptOptimisation</span></a></span><span>    </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">OptimisationLevel -&gt; Flag GhcOptimisation
</span><a href="Distribution.Simple.GHC.Internal.html#toGhcOptimisation"><span class="hs-identifier hs-var">toGhcOptimisation</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">LocalBuildInfo -&gt; OptimisationLevel
</span><a href="Distribution.Types.LocalBuildInfo.html#withOptimization"><span class="hs-identifier hs-var hs-var">withOptimization</span></a></span><span> </span><span class="annot"><span class="annottext">LocalBuildInfo
</span><a href="#local-6989586621679716866"><span class="hs-identifier hs-var">lbi</span></a></span><span class="hs-special">)</span><span class="hs-special">,</span><span>
</span><span id="line-427"></span><span>      </span><span class="annot"><span class="annottext">ghcOptDebugInfo :: Flag DebugInfoLevel
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptDebugInfo"><span class="hs-identifier hs-var">ghcOptDebugInfo</span></a></span><span>       </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">DebugInfoLevel -&gt; Flag DebugInfoLevel
forall a. a -&gt; Flag a
</span><a href="Distribution.Simple.Flag.html#toFlag"><span class="hs-identifier hs-var">toFlag</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">LocalBuildInfo -&gt; DebugInfoLevel
</span><a href="Distribution.Types.LocalBuildInfo.html#withDebugInfo"><span class="hs-identifier hs-var hs-var">withDebugInfo</span></a></span><span> </span><span class="annot"><span class="annottext">LocalBuildInfo
</span><a href="#local-6989586621679716866"><span class="hs-identifier hs-var">lbi</span></a></span><span class="hs-special">)</span><span class="hs-special">,</span><span>
</span><span id="line-428"></span><span>      </span><span class="annot"><span class="annottext">ghcOptExtra :: [String]
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptExtra"><span class="hs-identifier hs-var">ghcOptExtra</span></a></span><span>           </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">CompilerFlavor -&gt; BuildInfo -&gt; [String]
</span><a href="Distribution.Types.BuildInfo.html#hcOptions"><span class="hs-identifier hs-var">hcOptions</span></a></span><span> </span><span class="annot"><span class="annottext">CompilerFlavor
</span><a href="Distribution.Compiler.html#GHC"><span class="hs-identifier hs-var">GHC</span></a></span><span> </span><span class="annot"><span class="annottext">BuildInfo
</span><a href="#local-6989586621679716865"><span class="hs-identifier hs-var">bi</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-429"></span><span>      </span><span class="annot"><span class="annottext">ghcOptExtraPath :: NubListR String
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptExtraPath"><span class="hs-identifier hs-var">ghcOptExtraPath</span></a></span><span>       </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">[String] -&gt; NubListR String
forall a. Ord a =&gt; [a] -&gt; NubListR a
</span><a href="Distribution.Utils.NubList.html#toNubListR"><span class="hs-identifier hs-var">toNubListR</span></a></span><span> </span><span class="annot"><span class="annottext">([String] -&gt; NubListR String) -&gt; [String] -&gt; NubListR String
forall a b. (a -&gt; b) -&gt; a -&gt; b
</span><a href="../../base/src/GHC.Base.html#%24"><span class="hs-operator hs-var">$</span></a></span><span> </span><span class="annot"><span class="annottext">[String]
</span><a href="#local-6989586621679716821"><span class="hs-identifier hs-var">exe_paths</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-430"></span><span>      </span><span class="annot"><span class="annottext">ghcOptLanguage :: Flag Language
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptLanguage"><span class="hs-identifier hs-var">ghcOptLanguage</span></a></span><span>        </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Language -&gt; Flag Language
forall a. a -&gt; Flag a
</span><a href="Distribution.Simple.Flag.html#toFlag"><span class="hs-identifier hs-var">toFlag</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">Language -&gt; Maybe Language -&gt; Language
forall a. a -&gt; Maybe a -&gt; a
</span><a href="../../base/src/Data.Maybe.html#fromMaybe"><span class="hs-identifier hs-var">fromMaybe</span></a></span><span> </span><span class="annot"><span class="annottext">Language
</span><a href="Language.Haskell.Extension.html#Haskell98"><span class="hs-identifier hs-var">Haskell98</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">BuildInfo -&gt; Maybe Language
</span><a href="Distribution.Types.BuildInfo.html#defaultLanguage"><span class="hs-identifier hs-var hs-var">defaultLanguage</span></a></span><span> </span><span class="annot"><span class="annottext">BuildInfo
</span><a href="#local-6989586621679716865"><span class="hs-identifier hs-var">bi</span></a></span><span class="hs-special">)</span><span class="hs-special">)</span><span class="hs-special">,</span><span>
</span><span id="line-431"></span><span>      </span><span class="hs-comment">-- Unsupported extensions have already been checked by configure</span><span>
</span><span id="line-432"></span><span>      </span><span class="annot"><span class="annottext">ghcOptExtensions :: NubListR Extension
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptExtensions"><span class="hs-identifier hs-var">ghcOptExtensions</span></a></span><span>      </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">[Extension] -&gt; NubListR Extension
forall a. Ord a =&gt; [a] -&gt; NubListR a
</span><a href="Distribution.Utils.NubList.html#toNubListR"><span class="hs-identifier hs-var">toNubListR</span></a></span><span> </span><span class="annot"><span class="annottext">([Extension] -&gt; NubListR Extension)
-&gt; [Extension] -&gt; NubListR Extension
forall a b. (a -&gt; b) -&gt; a -&gt; b
</span><a href="../../base/src/GHC.Base.html#%24"><span class="hs-operator hs-var">$</span></a></span><span> </span><span class="annot"><span class="annottext">BuildInfo -&gt; [Extension]
</span><a href="Distribution.Types.BuildInfo.html#usedExtensions"><span class="hs-identifier hs-var">usedExtensions</span></a></span><span> </span><span class="annot"><span class="annottext">BuildInfo
</span><a href="#local-6989586621679716865"><span class="hs-identifier hs-var">bi</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-433"></span><span>      </span><span class="annot"><span class="annottext">ghcOptExtensionMap :: Map Extension (Maybe String)
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptExtensionMap"><span class="hs-identifier hs-var">ghcOptExtensionMap</span></a></span><span>    </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">[(Extension, Maybe String)] -&gt; Map Extension (Maybe String)
forall k a. Ord k =&gt; [(k, a)] -&gt; Map k a
</span><a href="../../containers/src/Data.Map.Internal.html#fromList"><span class="hs-identifier hs-var">Map.fromList</span></a></span><span> </span><span class="annot"><span class="annottext">([(Extension, Maybe String)] -&gt; Map Extension (Maybe String))
-&gt; (Compiler -&gt; [(Extension, Maybe String)])
-&gt; Compiler
-&gt; Map Extension (Maybe String)
forall b c a. (b -&gt; c) -&gt; (a -&gt; b) -&gt; a -&gt; c
</span><a href="../../base/src/GHC.Base.html#."><span class="hs-operator hs-var">.</span></a></span><span> </span><span class="annot"><span class="annottext">Compiler -&gt; [(Extension, Maybe String)]
</span><a href="Distribution.Simple.Compiler.html#compilerExtensions"><span class="hs-identifier hs-var hs-var">compilerExtensions</span></a></span><span> </span><span class="annot"><span class="annottext">(Compiler -&gt; Map Extension (Maybe String))
-&gt; Compiler -&gt; Map Extension (Maybe String)
forall a b. (a -&gt; b) -&gt; a -&gt; b
</span><a href="../../base/src/GHC.Base.html#%24"><span class="hs-operator hs-var">$</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">LocalBuildInfo -&gt; Compiler
</span><a href="Distribution.Types.LocalBuildInfo.html#compiler"><span class="hs-identifier hs-var hs-var">compiler</span></a></span><span> </span><span class="annot"><span class="annottext">LocalBuildInfo
</span><a href="#local-6989586621679716866"><span class="hs-identifier hs-var">lbi</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-434"></span><span>    </span><span class="hs-special">}</span><span>
</span><span id="line-435"></span><span>  </span><span class="hs-keyword">where</span><span>
</span><span id="line-436"></span><span>    </span><span id="local-6989586621679716821"><span class="annot"><span class="annottext">exe_paths :: [String]
</span><a href="#local-6989586621679716821"><span class="hs-identifier hs-var hs-var">exe_paths</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="hs-special">[</span><span> </span><span class="annot"><span class="annottext">LocalBuildInfo -&gt; ComponentLocalBuildInfo -&gt; String
</span><a href="Distribution.Simple.LocalBuildInfo.html#componentBuildDir"><span class="hs-identifier hs-var">componentBuildDir</span></a></span><span> </span><span class="annot"><span class="annottext">LocalBuildInfo
</span><a href="#local-6989586621679716866"><span class="hs-identifier hs-var">lbi</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">TargetInfo -&gt; ComponentLocalBuildInfo
</span><a href="Distribution.Types.TargetInfo.html#targetCLBI"><span class="hs-identifier hs-var hs-var">targetCLBI</span></a></span><span> </span><span class="annot"><span class="annottext">TargetInfo
</span><a href="#local-6989586621679716809"><span class="hs-identifier hs-var">exe_tgt</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-437"></span><span>                </span><span class="hs-glyph">|</span><span> </span><span id="local-6989586621679716808"><span class="annot"><span class="annottext">UnitId
</span><a href="#local-6989586621679716808"><span class="hs-identifier hs-var">uid</span></a></span></span><span> </span><span class="hs-glyph">&lt;-</span><span> </span><span class="annot"><span class="annottext">ComponentLocalBuildInfo -&gt; [UnitId]
</span><a href="Distribution.Types.ComponentLocalBuildInfo.html#componentExeDeps"><span class="hs-identifier hs-var hs-var">componentExeDeps</span></a></span><span> </span><span class="annot"><span class="annottext">ComponentLocalBuildInfo
</span><a href="#local-6989586621679716864"><span class="hs-identifier hs-var">clbi</span></a></span><span>
</span><span id="line-438"></span><span>                </span><span class="hs-comment">-- TODO: Ugh, localPkgDescr</span><span>
</span><span id="line-439"></span><span>                </span><span class="hs-special">,</span><span> </span><span class="annot"><a href="../../base/src/GHC.Maybe.html#Just"><span class="hs-identifier hs-type">Just</span></a></span><span> </span><span id="local-6989586621679716809"><span class="annot"><span class="annottext">TargetInfo
</span><a href="#local-6989586621679716809"><span class="hs-identifier hs-var">exe_tgt</span></a></span></span><span> </span><span class="hs-glyph">&lt;-</span><span> </span><span class="hs-special">[</span><span class="annot"><span class="annottext">PackageDescription -&gt; LocalBuildInfo -&gt; UnitId -&gt; Maybe TargetInfo
</span><a href="Distribution.Types.LocalBuildInfo.html#unitIdTarget%27"><span class="hs-identifier hs-var">unitIdTarget'</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">LocalBuildInfo -&gt; PackageDescription
</span><a href="Distribution.Types.LocalBuildInfo.html#localPkgDescr"><span class="hs-identifier hs-var hs-var">localPkgDescr</span></a></span><span> </span><span class="annot"><span class="annottext">LocalBuildInfo
</span><a href="#local-6989586621679716866"><span class="hs-identifier hs-var">lbi</span></a></span><span class="hs-special">)</span><span> </span><span class="annot"><span class="annottext">LocalBuildInfo
</span><a href="#local-6989586621679716866"><span class="hs-identifier hs-var">lbi</span></a></span><span> </span><span class="annot"><span class="annottext">UnitId
</span><a href="#local-6989586621679716808"><span class="hs-identifier hs-var">uid</span></a></span><span class="hs-special">]</span><span> </span><span class="hs-special">]</span><span>
</span><span id="line-440"></span><span>
</span><span id="line-441"></span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#toGhcOptimisation"><span class="hs-identifier hs-type">toGhcOptimisation</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="Distribution.Simple.Compiler.html#OptimisationLevel"><span class="hs-identifier hs-type">OptimisationLevel</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="Distribution.Simple.Flag.html#Flag"><span class="hs-identifier hs-type">Flag</span></a></span><span> </span><span class="annot"><a href="Distribution.Simple.Program.GHC.html#GhcOptimisation"><span class="hs-identifier hs-type">GhcOptimisation</span></a></span><span>
</span><span id="line-442"></span><span id="toGhcOptimisation"><span class="annot"><span class="annottext">toGhcOptimisation :: OptimisationLevel -&gt; Flag GhcOptimisation
</span><a href="Distribution.Simple.GHC.Internal.html#toGhcOptimisation"><span class="hs-identifier hs-var hs-var">toGhcOptimisation</span></a></span></span><span> </span><span class="annot"><span class="annottext">OptimisationLevel
</span><a href="Distribution.Simple.Compiler.html#NoOptimisation"><span class="hs-identifier hs-var">NoOptimisation</span></a></span><span>      </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Flag GhcOptimisation
forall a. Monoid a =&gt; a
</span><a href="../../base/src/GHC.Base.html#mempty"><span class="hs-identifier hs-var">mempty</span></a></span><span> </span><span class="hs-comment">--TODO perhaps override?</span><span>
</span><span id="line-443"></span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#toGhcOptimisation"><span class="hs-identifier hs-var">toGhcOptimisation</span></a></span><span> </span><span class="annot"><span class="annottext">OptimisationLevel
</span><a href="Distribution.Simple.Compiler.html#NormalOptimisation"><span class="hs-identifier hs-var">NormalOptimisation</span></a></span><span>  </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">GhcOptimisation -&gt; Flag GhcOptimisation
forall a. a -&gt; Flag a
</span><a href="Distribution.Simple.Flag.html#toFlag"><span class="hs-identifier hs-var">toFlag</span></a></span><span> </span><span class="annot"><span class="annottext">GhcOptimisation
</span><a href="Distribution.Simple.Program.GHC.html#GhcNormalOptimisation"><span class="hs-identifier hs-var">GhcNormalOptimisation</span></a></span><span>
</span><span id="line-444"></span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#toGhcOptimisation"><span class="hs-identifier hs-var">toGhcOptimisation</span></a></span><span> </span><span class="annot"><span class="annottext">OptimisationLevel
</span><a href="Distribution.Simple.Compiler.html#MaximumOptimisation"><span class="hs-identifier hs-var">MaximumOptimisation</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">GhcOptimisation -&gt; Flag GhcOptimisation
forall a. a -&gt; Flag a
</span><a href="Distribution.Simple.Flag.html#toFlag"><span class="hs-identifier hs-var">toFlag</span></a></span><span> </span><span class="annot"><span class="annottext">GhcOptimisation
</span><a href="Distribution.Simple.Program.GHC.html#GhcMaximumOptimisation"><span class="hs-identifier hs-var">GhcMaximumOptimisation</span></a></span><span>
</span><span id="line-445"></span><span>
</span><span id="line-446"></span><span>
</span><span id="line-447"></span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#componentCmmGhcOptions"><span class="hs-identifier hs-type">componentCmmGhcOptions</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="Distribution.Verbosity.html#Verbosity"><span class="hs-identifier hs-type">Verbosity</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="Distribution.Simple.GHC.ImplInfo.html#GhcImplInfo"><span class="hs-identifier hs-type">GhcImplInfo</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="Distribution.Types.LocalBuildInfo.html#LocalBuildInfo"><span class="hs-identifier hs-type">LocalBuildInfo</span></a></span><span>
</span><span id="line-448"></span><span>                      </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="Distribution.Types.BuildInfo.html#BuildInfo"><span class="hs-identifier hs-type">BuildInfo</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="Distribution.Types.ComponentLocalBuildInfo.html#ComponentLocalBuildInfo"><span class="hs-identifier hs-type">ComponentLocalBuildInfo</span></a></span><span>
</span><span id="line-449"></span><span>                      </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="../../base/src/GHC.IO.html#FilePath"><span class="hs-identifier hs-type">FilePath</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="../../base/src/GHC.IO.html#FilePath"><span class="hs-identifier hs-type">FilePath</span></a></span><span>
</span><span id="line-450"></span><span>                      </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="Distribution.Simple.Program.GHC.html#GhcOptions"><span class="hs-identifier hs-type">GhcOptions</span></a></span><span>
</span><span id="line-451"></span><span id="componentCmmGhcOptions"><span class="annot"><span class="annottext">componentCmmGhcOptions :: Verbosity
-&gt; GhcImplInfo
-&gt; LocalBuildInfo
-&gt; BuildInfo
-&gt; ComponentLocalBuildInfo
-&gt; String
-&gt; String
-&gt; GhcOptions
</span><a href="Distribution.Simple.GHC.Internal.html#componentCmmGhcOptions"><span class="hs-identifier hs-var hs-var">componentCmmGhcOptions</span></a></span></span><span> </span><span id="local-6989586621679716800"><span class="annot"><span class="annottext">Verbosity
</span><a href="#local-6989586621679716800"><span class="hs-identifier hs-var">verbosity</span></a></span></span><span> </span><span id="local-6989586621679716799"><span class="annot"><span class="annottext">GhcImplInfo
</span><a href="#local-6989586621679716799"><span class="hs-identifier hs-var">_implInfo</span></a></span></span><span> </span><span id="local-6989586621679716798"><span class="annot"><span class="annottext">LocalBuildInfo
</span><a href="#local-6989586621679716798"><span class="hs-identifier hs-var">lbi</span></a></span></span><span> </span><span id="local-6989586621679716797"><span class="annot"><span class="annottext">BuildInfo
</span><a href="#local-6989586621679716797"><span class="hs-identifier hs-var">bi</span></a></span></span><span> </span><span id="local-6989586621679716796"><span class="annot"><span class="annottext">ComponentLocalBuildInfo
</span><a href="#local-6989586621679716796"><span class="hs-identifier hs-var">clbi</span></a></span></span><span> </span><span id="local-6989586621679716795"><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716795"><span class="hs-identifier hs-var">odir</span></a></span></span><span> </span><span id="local-6989586621679716794"><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716794"><span class="hs-identifier hs-var">filename</span></a></span></span><span> </span><span class="hs-glyph">=</span><span>
</span><span id="line-452"></span><span>    </span><span class="annot"><span class="annottext">GhcOptions
forall a. Monoid a =&gt; a
</span><a href="../../base/src/GHC.Base.html#mempty"><span class="hs-identifier hs-var">mempty</span></a></span><span> </span><span class="hs-special">{</span><span>
</span><span id="line-453"></span><span>      </span><span class="hs-comment">-- Respect -v0, but don't crank up verbosity on GHC if</span><span>
</span><span id="line-454"></span><span>      </span><span class="hs-comment">-- Cabal verbosity is requested. For that, use --ghc-option=-v instead!</span><span>
</span><span id="line-455"></span><span>      </span><span class="annot"><span class="annottext">ghcOptVerbosity :: Flag Verbosity
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptVerbosity"><span class="hs-identifier hs-var">ghcOptVerbosity</span></a></span><span>      </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Verbosity -&gt; Flag Verbosity
forall a. a -&gt; Flag a
</span><a href="Distribution.Simple.Flag.html#toFlag"><span class="hs-identifier hs-var">toFlag</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">Verbosity -&gt; Verbosity -&gt; Verbosity
forall a. Ord a =&gt; a -&gt; a -&gt; a
</span><span class="hs-identifier hs-var">min</span></span><span> </span><span class="annot"><span class="annottext">Verbosity
</span><a href="#local-6989586621679716800"><span class="hs-identifier hs-var">verbosity</span></a></span><span> </span><span class="annot"><span class="annottext">Verbosity
</span><a href="Distribution.Verbosity.html#normal"><span class="hs-identifier hs-var">normal</span></a></span><span class="hs-special">)</span><span class="hs-special">,</span><span>
</span><span id="line-456"></span><span>      </span><span class="annot"><span class="annottext">ghcOptMode :: Flag GhcMode
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptMode"><span class="hs-identifier hs-var">ghcOptMode</span></a></span><span>           </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">GhcMode -&gt; Flag GhcMode
forall a. a -&gt; Flag a
</span><a href="Distribution.Simple.Flag.html#toFlag"><span class="hs-identifier hs-var">toFlag</span></a></span><span> </span><span class="annot"><span class="annottext">GhcMode
</span><a href="Distribution.Simple.Program.GHC.html#GhcModeCompile"><span class="hs-identifier hs-var">GhcModeCompile</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-457"></span><span>      </span><span class="annot"><span class="annottext">ghcOptInputFiles :: NubListR String
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptInputFiles"><span class="hs-identifier hs-var">ghcOptInputFiles</span></a></span><span>     </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">[String] -&gt; NubListR String
forall a. Ord a =&gt; [a] -&gt; NubListR a
</span><a href="Distribution.Utils.NubList.html#toNubListR"><span class="hs-identifier hs-var">toNubListR</span></a></span><span> </span><span class="hs-special">[</span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716794"><span class="hs-identifier hs-var">filename</span></a></span><span class="hs-special">]</span><span class="hs-special">,</span><span>
</span><span id="line-458"></span><span>
</span><span id="line-459"></span><span>      </span><span class="annot"><span class="annottext">ghcOptCppIncludePath :: NubListR String
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptCppIncludePath"><span class="hs-identifier hs-var">ghcOptCppIncludePath</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">[String] -&gt; NubListR String
forall a. Ord a =&gt; [a] -&gt; NubListR a
</span><a href="Distribution.Utils.NubList.html#toNubListR"><span class="hs-identifier hs-var">toNubListR</span></a></span><span> </span><span class="annot"><span class="annottext">([String] -&gt; NubListR String) -&gt; [String] -&gt; NubListR String
forall a b. (a -&gt; b) -&gt; a -&gt; b
</span><a href="../../base/src/GHC.Base.html#%24"><span class="hs-operator hs-var">$</span></a></span><span> </span><span class="hs-special">[</span><span class="annot"><span class="annottext">LocalBuildInfo -&gt; ComponentLocalBuildInfo -&gt; String
</span><a href="Distribution.Simple.BuildPaths.html#autogenComponentModulesDir"><span class="hs-identifier hs-var">autogenComponentModulesDir</span></a></span><span> </span><span class="annot"><span class="annottext">LocalBuildInfo
</span><a href="#local-6989586621679716798"><span class="hs-identifier hs-var">lbi</span></a></span><span> </span><span class="annot"><span class="annottext">ComponentLocalBuildInfo
</span><a href="#local-6989586621679716796"><span class="hs-identifier hs-var">clbi</span></a></span><span>
</span><span id="line-460"></span><span>                                          </span><span class="hs-special">,</span><span class="annot"><span class="annottext">LocalBuildInfo -&gt; String
</span><a href="Distribution.Simple.BuildPaths.html#autogenPackageModulesDir"><span class="hs-identifier hs-var">autogenPackageModulesDir</span></a></span><span> </span><span class="annot"><span class="annottext">LocalBuildInfo
</span><a href="#local-6989586621679716798"><span class="hs-identifier hs-var">lbi</span></a></span><span>
</span><span id="line-461"></span><span>                                          </span><span class="hs-special">,</span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716795"><span class="hs-identifier hs-var">odir</span></a></span><span class="hs-special">]</span><span>
</span><span id="line-462"></span><span>                                          </span><span class="hs-comment">-- includes relative to the package</span><span>
</span><span id="line-463"></span><span>                                          </span><span class="annot"><span class="annottext">[String] -&gt; [String] -&gt; [String]
forall a. [a] -&gt; [a] -&gt; [a]
</span><a href="../../base/src/GHC.Base.html#%2B%2B"><span class="hs-operator hs-var">++</span></a></span><span> </span><span class="annot"><span class="annottext">BuildInfo -&gt; [String]
</span><a href="Distribution.Types.BuildInfo.html#includeDirs"><span class="hs-identifier hs-var hs-var">includeDirs</span></a></span><span> </span><span class="annot"><span class="annottext">BuildInfo
</span><a href="#local-6989586621679716797"><span class="hs-identifier hs-var">bi</span></a></span><span>
</span><span id="line-464"></span><span>                                          </span><span class="hs-comment">-- potential includes generated by `configure'</span><span>
</span><span id="line-465"></span><span>                                          </span><span class="hs-comment">-- in the build directory</span><span>
</span><span id="line-466"></span><span>                                          </span><span class="annot"><span class="annottext">[String] -&gt; [String] -&gt; [String]
forall a. [a] -&gt; [a] -&gt; [a]
</span><a href="../../base/src/GHC.Base.html#%2B%2B"><span class="hs-operator hs-var">++</span></a></span><span> </span><span class="hs-special">[</span><span class="annot"><span class="annottext">LocalBuildInfo -&gt; String
</span><a href="Distribution.Types.LocalBuildInfo.html#buildDir"><span class="hs-identifier hs-var hs-var">buildDir</span></a></span><span> </span><span class="annot"><span class="annottext">LocalBuildInfo
</span><a href="#local-6989586621679716798"><span class="hs-identifier hs-var">lbi</span></a></span><span> </span><span class="annot"><span class="annottext">String -&gt; String -&gt; String
</span><a href="../../filepath/src/System.FilePath.Windows.html#%3C%2F%3E"><span class="hs-operator hs-var">&lt;/&gt;</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716793"><span class="hs-identifier hs-var">dir</span></a></span><span> </span><span class="hs-glyph">|</span><span> </span><span id="local-6989586621679716793"><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716793"><span class="hs-identifier hs-var">dir</span></a></span></span><span> </span><span class="hs-glyph">&lt;-</span><span> </span><span class="annot"><span class="annottext">BuildInfo -&gt; [String]
</span><a href="Distribution.Types.BuildInfo.html#includeDirs"><span class="hs-identifier hs-var hs-var">includeDirs</span></a></span><span> </span><span class="annot"><span class="annottext">BuildInfo
</span><a href="#local-6989586621679716797"><span class="hs-identifier hs-var">bi</span></a></span><span class="hs-special">]</span><span class="hs-special">,</span><span>
</span><span id="line-467"></span><span>      </span><span class="annot"><span class="annottext">ghcOptCppOptions :: [String]
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptCppOptions"><span class="hs-identifier hs-var">ghcOptCppOptions</span></a></span><span>     </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">BuildInfo -&gt; [String]
</span><a href="Distribution.Types.BuildInfo.html#cppOptions"><span class="hs-identifier hs-var hs-var">cppOptions</span></a></span><span> </span><span class="annot"><span class="annottext">BuildInfo
</span><a href="#local-6989586621679716797"><span class="hs-identifier hs-var">bi</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-468"></span><span>      </span><span class="annot"><span class="annottext">ghcOptCppIncludes :: NubListR String
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptCppIncludes"><span class="hs-identifier hs-var">ghcOptCppIncludes</span></a></span><span>    </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">[String] -&gt; NubListR String
forall a. Ord a =&gt; [a] -&gt; NubListR a
</span><a href="Distribution.Utils.NubList.html#toNubListR"><span class="hs-identifier hs-var">toNubListR</span></a></span><span> </span><span class="annot"><span class="annottext">([String] -&gt; NubListR String) -&gt; [String] -&gt; NubListR String
forall a b. (a -&gt; b) -&gt; a -&gt; b
</span><a href="../../base/src/GHC.Base.html#%24"><span class="hs-operator hs-var">$</span></a></span><span>
</span><span id="line-469"></span><span>                             </span><span class="hs-special">[</span><span class="annot"><span class="annottext">LocalBuildInfo -&gt; ComponentLocalBuildInfo -&gt; String
</span><a href="Distribution.Simple.BuildPaths.html#autogenComponentModulesDir"><span class="hs-identifier hs-var">autogenComponentModulesDir</span></a></span><span> </span><span class="annot"><span class="annottext">LocalBuildInfo
</span><a href="#local-6989586621679716798"><span class="hs-identifier hs-var">lbi</span></a></span><span> </span><span class="annot"><span class="annottext">ComponentLocalBuildInfo
</span><a href="#local-6989586621679716796"><span class="hs-identifier hs-var">clbi</span></a></span><span> </span><span class="annot"><span class="annottext">String -&gt; String -&gt; String
</span><a href="../../filepath/src/System.FilePath.Windows.html#%3C%2F%3E"><span class="hs-operator hs-var">&lt;/&gt;</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><a href="Distribution.Simple.BuildPaths.html#cppHeaderName"><span class="hs-identifier hs-var">cppHeaderName</span></a></span><span class="hs-special">]</span><span class="hs-special">,</span><span>
</span><span id="line-470"></span><span>      </span><span class="annot"><span class="annottext">ghcOptHideAllPackages :: Flag Bool
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptHideAllPackages"><span class="hs-identifier hs-var">ghcOptHideAllPackages</span></a></span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Bool -&gt; Flag Bool
forall a. a -&gt; Flag a
</span><a href="Distribution.Simple.Flag.html#toFlag"><span class="hs-identifier hs-var">toFlag</span></a></span><span> </span><span class="annot"><span class="annottext">Bool
</span><span class="hs-identifier hs-var">True</span></span><span class="hs-special">,</span><span>
</span><span id="line-471"></span><span>      </span><span class="annot"><span class="annottext">ghcOptPackageDBs :: PackageDBStack
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptPackageDBs"><span class="hs-identifier hs-var">ghcOptPackageDBs</span></a></span><span>     </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">LocalBuildInfo -&gt; PackageDBStack
</span><a href="Distribution.Types.LocalBuildInfo.html#withPackageDB"><span class="hs-identifier hs-var hs-var">withPackageDB</span></a></span><span> </span><span class="annot"><span class="annottext">LocalBuildInfo
</span><a href="#local-6989586621679716798"><span class="hs-identifier hs-var">lbi</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-472"></span><span>      </span><span class="annot"><span class="annottext">ghcOptPackages :: NubListR (OpenUnitId, ModuleRenaming)
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptPackages"><span class="hs-identifier hs-var">ghcOptPackages</span></a></span><span>       </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">[(OpenUnitId, ModuleRenaming)]
-&gt; NubListR (OpenUnitId, ModuleRenaming)
forall a. Ord a =&gt; [a] -&gt; NubListR a
</span><a href="Distribution.Utils.NubList.html#toNubListR"><span class="hs-identifier hs-var">toNubListR</span></a></span><span> </span><span class="annot"><span class="annottext">([(OpenUnitId, ModuleRenaming)]
 -&gt; NubListR (OpenUnitId, ModuleRenaming))
-&gt; [(OpenUnitId, ModuleRenaming)]
-&gt; NubListR (OpenUnitId, ModuleRenaming)
forall a b. (a -&gt; b) -&gt; a -&gt; b
</span><a href="../../base/src/GHC.Base.html#%24"><span class="hs-operator hs-var">$</span></a></span><span> </span><span class="annot"><span class="annottext">ComponentLocalBuildInfo -&gt; [(OpenUnitId, ModuleRenaming)]
</span><a href="Distribution.Simple.GHC.Internal.html#mkGhcOptPackages"><span class="hs-identifier hs-var">mkGhcOptPackages</span></a></span><span> </span><span class="annot"><span class="annottext">ComponentLocalBuildInfo
</span><a href="#local-6989586621679716796"><span class="hs-identifier hs-var">clbi</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-473"></span><span>      </span><span class="annot"><span class="annottext">ghcOptOptimisation :: Flag GhcOptimisation
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptOptimisation"><span class="hs-identifier hs-var">ghcOptOptimisation</span></a></span><span>   </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">OptimisationLevel -&gt; Flag GhcOptimisation
</span><a href="Distribution.Simple.GHC.Internal.html#toGhcOptimisation"><span class="hs-identifier hs-var">toGhcOptimisation</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">LocalBuildInfo -&gt; OptimisationLevel
</span><a href="Distribution.Types.LocalBuildInfo.html#withOptimization"><span class="hs-identifier hs-var hs-var">withOptimization</span></a></span><span> </span><span class="annot"><span class="annottext">LocalBuildInfo
</span><a href="#local-6989586621679716798"><span class="hs-identifier hs-var">lbi</span></a></span><span class="hs-special">)</span><span class="hs-special">,</span><span>
</span><span id="line-474"></span><span>      </span><span class="annot"><span class="annottext">ghcOptDebugInfo :: Flag DebugInfoLevel
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptDebugInfo"><span class="hs-identifier hs-var">ghcOptDebugInfo</span></a></span><span>      </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">DebugInfoLevel -&gt; Flag DebugInfoLevel
forall a. a -&gt; Flag a
</span><a href="Distribution.Simple.Flag.html#toFlag"><span class="hs-identifier hs-var">toFlag</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">LocalBuildInfo -&gt; DebugInfoLevel
</span><a href="Distribution.Types.LocalBuildInfo.html#withDebugInfo"><span class="hs-identifier hs-var hs-var">withDebugInfo</span></a></span><span> </span><span class="annot"><span class="annottext">LocalBuildInfo
</span><a href="#local-6989586621679716798"><span class="hs-identifier hs-var">lbi</span></a></span><span class="hs-special">)</span><span class="hs-special">,</span><span>
</span><span id="line-475"></span><span>      </span><span class="annot"><span class="annottext">ghcOptExtra :: [String]
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptExtra"><span class="hs-identifier hs-var">ghcOptExtra</span></a></span><span>          </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">BuildInfo -&gt; [String]
</span><a href="Distribution.Types.BuildInfo.html#cmmOptions"><span class="hs-identifier hs-var hs-var">cmmOptions</span></a></span><span> </span><span class="annot"><span class="annottext">BuildInfo
</span><a href="#local-6989586621679716797"><span class="hs-identifier hs-var">bi</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-476"></span><span>      </span><span class="annot"><span class="annottext">ghcOptObjDir :: Flag String
</span><a href="Distribution.Simple.Program.GHC.html#ghcOptObjDir"><span class="hs-identifier hs-var">ghcOptObjDir</span></a></span><span>         </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; Flag String
forall a. a -&gt; Flag a
</span><a href="Distribution.Simple.Flag.html#toFlag"><span class="hs-identifier hs-var">toFlag</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716795"><span class="hs-identifier hs-var">odir</span></a></span><span>
</span><span id="line-477"></span><span>    </span><span class="hs-special">}</span><span>
</span><span id="line-478"></span><span>
</span><span id="line-479"></span><span>
</span><span id="line-480"></span><span class="hs-comment">-- | Strip out flags that are not supported in ghci</span><span>
</span><span id="line-481"></span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#filterGhciFlags"><span class="hs-identifier hs-type">filterGhciFlags</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="hs-special">[</span><span class="annot"><a href="../../base/src/GHC.Base.html#String"><span class="hs-identifier hs-type">String</span></a></span><span class="hs-special">]</span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="hs-special">[</span><span class="annot"><a href="../../base/src/GHC.Base.html#String"><span class="hs-identifier hs-type">String</span></a></span><span class="hs-special">]</span><span>
</span><span id="line-482"></span><span id="filterGhciFlags"><span class="annot"><span class="annottext">filterGhciFlags :: [String] -&gt; [String]
</span><a href="Distribution.Simple.GHC.Internal.html#filterGhciFlags"><span class="hs-identifier hs-var hs-var">filterGhciFlags</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">(String -&gt; Bool) -&gt; [String] -&gt; [String]
forall a. (a -&gt; Bool) -&gt; [a] -&gt; [a]
</span><a href="../../base/src/GHC.List.html#filter"><span class="hs-identifier hs-var">filter</span></a></span><span> </span><span class="annot"><span class="annottext">String -&gt; Bool
</span><a href="#local-6989586621679716791"><span class="hs-identifier hs-var">supported</span></a></span><span>
</span><span id="line-483"></span><span>  </span><span class="hs-keyword">where</span><span>
</span><span id="line-484"></span><span>    </span><span id="local-6989586621679716791"><span class="annot"><span class="annottext">supported :: String -&gt; Bool
</span><a href="#local-6989586621679716791"><span class="hs-identifier hs-var hs-var">supported</span></a></span></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">Char
</span><span class="hs-char">'-'</span></span><span class="annot"><span class="hs-glyph hs-type">:</span></span><span class="annot"><span class="annottext">Char
</span><span class="hs-char">'O'</span></span><span class="annot"><span class="hs-glyph hs-type">:</span></span><span class="annot"><span class="annottext">String
</span><span class="hs-identifier">_</span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Bool
</span><span class="hs-identifier hs-var">False</span></span><span>
</span><span id="line-485"></span><span>    </span><span class="annot"><a href="#local-6989586621679716791"><span class="hs-identifier hs-var">supported</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;-debug&quot;</span></span><span>    </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Bool
</span><span class="hs-identifier hs-var">False</span></span><span>
</span><span id="line-486"></span><span>    </span><span class="annot"><a href="#local-6989586621679716791"><span class="hs-identifier hs-var">supported</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;-threaded&quot;</span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Bool
</span><span class="hs-identifier hs-var">False</span></span><span>
</span><span id="line-487"></span><span>    </span><span class="annot"><a href="#local-6989586621679716791"><span class="hs-identifier hs-var">supported</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;-ticky&quot;</span></span><span>    </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Bool
</span><span class="hs-identifier hs-var">False</span></span><span>
</span><span id="line-488"></span><span>    </span><span class="annot"><a href="#local-6989586621679716791"><span class="hs-identifier hs-var">supported</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;-eventlog&quot;</span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Bool
</span><span class="hs-identifier hs-var">False</span></span><span>
</span><span id="line-489"></span><span>    </span><span class="annot"><a href="#local-6989586621679716791"><span class="hs-identifier hs-var">supported</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;-prof&quot;</span></span><span>     </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Bool
</span><span class="hs-identifier hs-var">False</span></span><span>
</span><span id="line-490"></span><span>    </span><span class="annot"><a href="#local-6989586621679716791"><span class="hs-identifier hs-var">supported</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;-unreg&quot;</span></span><span>    </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Bool
</span><span class="hs-identifier hs-var">False</span></span><span>
</span><span id="line-491"></span><span>    </span><span class="annot"><a href="#local-6989586621679716791"><span class="hs-identifier hs-var">supported</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-identifier">_</span></span><span>           </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Bool
</span><span class="hs-identifier hs-var">True</span></span><span>
</span><span id="line-492"></span><span>
</span><span id="line-493"></span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#mkGHCiLibName"><span class="hs-identifier hs-type">mkGHCiLibName</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="Distribution.Types.UnitId.html#UnitId"><span class="hs-identifier hs-type">UnitId</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="../../base/src/GHC.Base.html#String"><span class="hs-identifier hs-type">String</span></a></span><span>
</span><span id="line-494"></span><span id="mkGHCiLibName"><span class="annot"><span class="annottext">mkGHCiLibName :: UnitId -&gt; String
</span><a href="Distribution.Simple.GHC.Internal.html#mkGHCiLibName"><span class="hs-identifier hs-var hs-var">mkGHCiLibName</span></a></span></span><span> </span><span id="local-6989586621679716790"><span class="annot"><span class="annottext">UnitId
</span><a href="#local-6989586621679716790"><span class="hs-identifier hs-var">lib</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">UnitId -&gt; String
</span><a href="Distribution.Types.UnitId.html#getHSLibraryName"><span class="hs-identifier hs-var">getHSLibraryName</span></a></span><span> </span><span class="annot"><span class="annottext">UnitId
</span><a href="#local-6989586621679716790"><span class="hs-identifier hs-var">lib</span></a></span><span> </span><span class="annot"><span class="annottext">String -&gt; String -&gt; String
</span><a href="../../filepath/src/System.FilePath.Windows.html#%3C.%3E"><span class="hs-operator hs-var">&lt;.&gt;</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;o&quot;</span></span><span>
</span><span id="line-495"></span><span>
</span><span id="line-496"></span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#mkGHCiProfLibName"><span class="hs-identifier hs-type">mkGHCiProfLibName</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="Distribution.Types.UnitId.html#UnitId"><span class="hs-identifier hs-type">UnitId</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="../../base/src/GHC.Base.html#String"><span class="hs-identifier hs-type">String</span></a></span><span>
</span><span id="line-497"></span><span id="mkGHCiProfLibName"><span class="annot"><span class="annottext">mkGHCiProfLibName :: UnitId -&gt; String
</span><a href="Distribution.Simple.GHC.Internal.html#mkGHCiProfLibName"><span class="hs-identifier hs-var hs-var">mkGHCiProfLibName</span></a></span></span><span> </span><span id="local-6989586621679716788"><span class="annot"><span class="annottext">UnitId
</span><a href="#local-6989586621679716788"><span class="hs-identifier hs-var">lib</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">UnitId -&gt; String
</span><a href="Distribution.Types.UnitId.html#getHSLibraryName"><span class="hs-identifier hs-var">getHSLibraryName</span></a></span><span> </span><span class="annot"><span class="annottext">UnitId
</span><a href="#local-6989586621679716788"><span class="hs-identifier hs-var">lib</span></a></span><span> </span><span class="annot"><span class="annottext">String -&gt; String -&gt; String
</span><a href="../../filepath/src/System.FilePath.Windows.html#%3C.%3E"><span class="hs-operator hs-var">&lt;.&gt;</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;p_o&quot;</span></span><span>
</span><span id="line-498"></span><span>
</span><span id="line-499"></span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#ghcLookupProperty"><span class="hs-identifier hs-type">ghcLookupProperty</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="../../base/src/GHC.Base.html#String"><span class="hs-identifier hs-type">String</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="Distribution.Simple.Compiler.html#Compiler"><span class="hs-identifier hs-type">Compiler</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="hs-identifier hs-type">Bool</span></span><span>
</span><span id="line-500"></span><span id="ghcLookupProperty"><span class="annot"><span class="annottext">ghcLookupProperty :: String -&gt; Compiler -&gt; Bool
</span><a href="Distribution.Simple.GHC.Internal.html#ghcLookupProperty"><span class="hs-identifier hs-var hs-var">ghcLookupProperty</span></a></span></span><span> </span><span id="local-6989586621679716787"><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716787"><span class="hs-identifier hs-var">prop</span></a></span></span><span> </span><span id="local-6989586621679716786"><span class="annot"><span class="annottext">Compiler
</span><a href="#local-6989586621679716786"><span class="hs-identifier hs-var">comp</span></a></span></span><span> </span><span class="hs-glyph">=</span><span>
</span><span id="line-501"></span><span>  </span><span class="hs-keyword">case</span><span> </span><span class="annot"><span class="annottext">String -&gt; Map String String -&gt; Maybe String
forall k a. Ord k =&gt; k -&gt; Map k a -&gt; Maybe a
</span><a href="../../containers/src/Data.Map.Internal.html#lookup"><span class="hs-identifier hs-var">Map.lookup</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716787"><span class="hs-identifier hs-var">prop</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">Compiler -&gt; Map String String
</span><a href="Distribution.Simple.Compiler.html#compilerProperties"><span class="hs-identifier hs-var hs-var">compilerProperties</span></a></span><span> </span><span class="annot"><span class="annottext">Compiler
</span><a href="#local-6989586621679716786"><span class="hs-identifier hs-var">comp</span></a></span><span class="hs-special">)</span><span> </span><span class="hs-keyword">of</span><span>
</span><span id="line-502"></span><span>    </span><span class="annot"><a href="../../base/src/GHC.Maybe.html#Just"><span class="hs-identifier hs-type">Just</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;YES&quot;</span></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">Bool
</span><span class="hs-identifier hs-var">True</span></span><span>
</span><span id="line-503"></span><span>    </span><span class="annot"><span class="annottext">Maybe String
</span><span class="hs-identifier">_</span></span><span>          </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">Bool
</span><span class="hs-identifier hs-var">False</span></span><span>
</span><span id="line-504"></span><span>
</span><span id="line-505"></span><span class="hs-comment">-- when using -split-objs, we need to search for object files in the</span><span>
</span><span id="line-506"></span><span class="hs-comment">-- Module_split directory for each module.</span><span>
</span><span id="line-507"></span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#getHaskellObjects"><span class="hs-identifier hs-type">getHaskellObjects</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="Distribution.Simple.GHC.ImplInfo.html#GhcImplInfo"><span class="hs-identifier hs-type">GhcImplInfo</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="Distribution.Types.Library.html#Library"><span class="hs-identifier hs-type">Library</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="Distribution.Types.LocalBuildInfo.html#LocalBuildInfo"><span class="hs-identifier hs-type">LocalBuildInfo</span></a></span><span>
</span><span id="line-508"></span><span>                  </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="Distribution.Types.ComponentLocalBuildInfo.html#ComponentLocalBuildInfo"><span class="hs-identifier hs-type">ComponentLocalBuildInfo</span></a></span><span>
</span><span id="line-509"></span><span>                  </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="../../base/src/GHC.IO.html#FilePath"><span class="hs-identifier hs-type">FilePath</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="../../base/src/GHC.Base.html#String"><span class="hs-identifier hs-type">String</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="hs-identifier hs-type">Bool</span></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="hs-identifier hs-type">IO</span></span><span> </span><span class="hs-special">[</span><span class="annot"><a href="../../base/src/GHC.IO.html#FilePath"><span class="hs-identifier hs-type">FilePath</span></a></span><span class="hs-special">]</span><span>
</span><span id="line-510"></span><span id="getHaskellObjects"><span class="annot"><span class="annottext">getHaskellObjects :: GhcImplInfo
-&gt; Library
-&gt; LocalBuildInfo
-&gt; ComponentLocalBuildInfo
-&gt; String
-&gt; String
-&gt; Bool
-&gt; IO [String]
</span><a href="Distribution.Simple.GHC.Internal.html#getHaskellObjects"><span class="hs-identifier hs-var hs-var">getHaskellObjects</span></a></span></span><span> </span><span id="local-6989586621679716784"><span class="annot"><span class="annottext">GhcImplInfo
</span><a href="#local-6989586621679716784"><span class="hs-identifier hs-var">_implInfo</span></a></span></span><span> </span><span id="local-6989586621679716783"><span class="annot"><span class="annottext">Library
</span><a href="#local-6989586621679716783"><span class="hs-identifier hs-var">lib</span></a></span></span><span> </span><span id="local-6989586621679716782"><span class="annot"><span class="annottext">LocalBuildInfo
</span><a href="#local-6989586621679716782"><span class="hs-identifier hs-var">lbi</span></a></span></span><span> </span><span id="local-6989586621679716781"><span class="annot"><span class="annottext">ComponentLocalBuildInfo
</span><a href="#local-6989586621679716781"><span class="hs-identifier hs-var">clbi</span></a></span></span><span> </span><span id="local-6989586621679716780"><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716780"><span class="hs-identifier hs-var">pref</span></a></span></span><span> </span><span id="local-6989586621679716779"><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716779"><span class="hs-identifier hs-var">wanted_obj_ext</span></a></span></span><span> </span><span id="local-6989586621679716778"><span class="annot"><span class="annottext">Bool
</span><a href="#local-6989586621679716778"><span class="hs-identifier hs-var">allow_split_objs</span></a></span></span><span>
</span><span id="line-511"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span class="annot"><span class="annottext">LocalBuildInfo -&gt; Bool
</span><a href="Distribution.Types.LocalBuildInfo.html#splitObjs"><span class="hs-identifier hs-var hs-var">splitObjs</span></a></span><span> </span><span class="annot"><span class="annottext">LocalBuildInfo
</span><a href="#local-6989586621679716782"><span class="hs-identifier hs-var">lbi</span></a></span><span> </span><span class="annot"><span class="annottext">Bool -&gt; Bool -&gt; Bool
</span><span class="hs-operator hs-var">&amp;&amp;</span></span><span> </span><span class="annot"><span class="annottext">Bool
</span><a href="#local-6989586621679716778"><span class="hs-identifier hs-var">allow_split_objs</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="hs-keyword">do</span><span>
</span><span id="line-512"></span><span>        </span><span class="hs-keyword">let</span><span> </span><span id="local-6989586621679716776"><span class="annot"><span class="annottext">splitSuffix :: String
</span><a href="#local-6989586621679716776"><span class="hs-identifier hs-var hs-var">splitSuffix</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;_&quot;</span></span><span> </span><span class="annot"><span class="annottext">String -&gt; String -&gt; String
forall a. [a] -&gt; [a] -&gt; [a]
</span><a href="../../base/src/GHC.Base.html#%2B%2B"><span class="hs-operator hs-var">++</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716779"><span class="hs-identifier hs-var">wanted_obj_ext</span></a></span><span> </span><span class="annot"><span class="annottext">String -&gt; String -&gt; String
forall a. [a] -&gt; [a] -&gt; [a]
</span><a href="../../base/src/GHC.Base.html#%2B%2B"><span class="hs-operator hs-var">++</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;_split&quot;</span></span><span>
</span><span id="line-513"></span><span>            </span><span id="local-6989586621679716775"><span class="annot"><span class="annottext">dirs :: [String]
</span><a href="#local-6989586621679716775"><span class="hs-identifier hs-var hs-var">dirs</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="hs-special">[</span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716780"><span class="hs-identifier hs-var">pref</span></a></span><span> </span><span class="annot"><span class="annottext">String -&gt; String -&gt; String
</span><a href="../../filepath/src/System.FilePath.Windows.html#%3C%2F%3E"><span class="hs-operator hs-var">&lt;/&gt;</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">ModuleName -&gt; String
</span><a href="Distribution.ModuleName.html#toFilePath"><span class="hs-identifier hs-var">ModuleName.toFilePath</span></a></span><span> </span><span class="annot"><span class="annottext">ModuleName
</span><a href="#local-6989586621679716773"><span class="hs-identifier hs-var">x</span></a></span><span> </span><span class="annot"><span class="annottext">String -&gt; String -&gt; String
forall a. [a] -&gt; [a] -&gt; [a]
</span><a href="../../base/src/GHC.Base.html#%2B%2B"><span class="hs-operator hs-var">++</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716776"><span class="hs-identifier hs-var">splitSuffix</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-514"></span><span>                   </span><span class="hs-glyph">|</span><span> </span><span id="local-6989586621679716773"><span class="annot"><span class="annottext">ModuleName
</span><a href="#local-6989586621679716773"><span class="hs-identifier hs-var">x</span></a></span></span><span> </span><span class="hs-glyph">&lt;-</span><span> </span><span class="annot"><span class="annottext">Library -&gt; ComponentLocalBuildInfo -&gt; [ModuleName]
</span><a href="Distribution.Simple.LocalBuildInfo.html#allLibModules"><span class="hs-identifier hs-var">allLibModules</span></a></span><span> </span><span class="annot"><span class="annottext">Library
</span><a href="#local-6989586621679716783"><span class="hs-identifier hs-var">lib</span></a></span><span> </span><span class="annot"><span class="annottext">ComponentLocalBuildInfo
</span><a href="#local-6989586621679716781"><span class="hs-identifier hs-var">clbi</span></a></span><span> </span><span class="hs-special">]</span><span>
</span><span id="line-515"></span><span>        </span><span id="local-6989586621679716771"><span class="annot"><span class="annottext">[[String]]
</span><a href="#local-6989586621679716771"><span class="hs-identifier hs-var">objss</span></a></span></span><span> </span><span class="hs-glyph">&lt;-</span><span> </span><span class="annot"><span class="annottext">(String -&gt; IO [String]) -&gt; [String] -&gt; IO [[String]]
forall (t :: * -&gt; *) (f :: * -&gt; *) a b.
(Traversable t, Applicative f) =&gt;
(a -&gt; f b) -&gt; t a -&gt; f (t b)
</span><a href="../../base/src/Data.Traversable.html#traverse"><span class="hs-identifier hs-var">traverse</span></a></span><span> </span><span class="annot"><span class="annottext">String -&gt; IO [String]
</span><a href="../../directory/src/System.Directory.html#getDirectoryContents"><span class="hs-identifier hs-var">getDirectoryContents</span></a></span><span> </span><span class="annot"><span class="annottext">[String]
</span><a href="#local-6989586621679716775"><span class="hs-identifier hs-var">dirs</span></a></span><span>
</span><span id="line-516"></span><span>        </span><span class="hs-keyword">let</span><span> </span><span id="local-6989586621679716767"><span class="annot"><span class="annottext">objs :: [String]
</span><a href="#local-6989586621679716767"><span class="hs-identifier hs-var hs-var">objs</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="hs-special">[</span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716766"><span class="hs-identifier hs-var">dir</span></a></span><span> </span><span class="annot"><span class="annottext">String -&gt; String -&gt; String
</span><a href="../../filepath/src/System.FilePath.Windows.html#%3C%2F%3E"><span class="hs-operator hs-var">&lt;/&gt;</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716765"><span class="hs-identifier hs-var">obj</span></a></span><span>
</span><span id="line-517"></span><span>                   </span><span class="hs-glyph">|</span><span> </span><span class="hs-special">(</span><span id="local-6989586621679716764"><span class="annot"><span class="annottext">[String]
</span><a href="#local-6989586621679716764"><span class="hs-identifier hs-var">objs'</span></a></span></span><span class="hs-special">,</span><span id="local-6989586621679716766"><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716766"><span class="hs-identifier hs-var">dir</span></a></span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">&lt;-</span><span> </span><span class="annot"><span class="annottext">[[String]] -&gt; [String] -&gt; [([String], String)]
forall a b. [a] -&gt; [b] -&gt; [(a, b)]
</span><a href="../../base/src/GHC.List.html#zip"><span class="hs-identifier hs-var">zip</span></a></span><span> </span><span class="annot"><span class="annottext">[[String]]
</span><a href="#local-6989586621679716771"><span class="hs-identifier hs-var">objss</span></a></span><span> </span><span class="annot"><span class="annottext">[String]
</span><a href="#local-6989586621679716775"><span class="hs-identifier hs-var">dirs</span></a></span><span class="hs-special">,</span><span> </span><span id="local-6989586621679716765"><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716765"><span class="hs-identifier hs-var">obj</span></a></span></span><span> </span><span class="hs-glyph">&lt;-</span><span> </span><span class="annot"><span class="annottext">[String]
</span><a href="#local-6989586621679716764"><span class="hs-identifier hs-var">objs'</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-518"></span><span>                     </span><span class="hs-keyword">let</span><span> </span><span id="local-6989586621679716763"><span class="annot"><span class="annottext">obj_ext :: String
</span><a href="#local-6989586621679716763"><span class="hs-identifier hs-var hs-var">obj_ext</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; String
</span><a href="../../filepath/src/System.FilePath.Windows.html#takeExtension"><span class="hs-identifier hs-var">takeExtension</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716765"><span class="hs-identifier hs-var">obj</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-519"></span><span>                     </span><span class="annot"><span class="annottext">Char
</span><span class="hs-char">'.'</span></span><span class="annot"><span class="annottext">Char -&gt; String -&gt; String
forall a. a -&gt; [a] -&gt; [a]
</span><span class="hs-glyph hs-var">:</span></span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716779"><span class="hs-identifier hs-var">wanted_obj_ext</span></a></span><span> </span><span class="annot"><span class="annottext">String -&gt; String -&gt; Bool
forall a. Eq a =&gt; a -&gt; a -&gt; Bool
</span><span class="hs-operator hs-var">==</span></span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716763"><span class="hs-identifier hs-var">obj_ext</span></a></span><span> </span><span class="hs-special">]</span><span>
</span><span id="line-520"></span><span>        </span><span class="annot"><span class="annottext">[String] -&gt; IO [String]
forall (m :: * -&gt; *) a. Monad m =&gt; a -&gt; m a
</span><a href="../../base/src/GHC.Base.html#return"><span class="hs-identifier hs-var">return</span></a></span><span> </span><span class="annot"><span class="annottext">[String]
</span><a href="#local-6989586621679716767"><span class="hs-identifier hs-var">objs</span></a></span><span>
</span><span id="line-521"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span class="annot"><span class="annottext">Bool
</span><a href="../../base/src/GHC.Base.html#otherwise"><span class="hs-identifier hs-var">otherwise</span></a></span><span>  </span><span class="hs-glyph">=</span><span>
</span><span id="line-522"></span><span>        </span><span class="annot"><span class="annottext">[String] -&gt; IO [String]
forall (m :: * -&gt; *) a. Monad m =&gt; a -&gt; m a
</span><a href="../../base/src/GHC.Base.html#return"><span class="hs-identifier hs-var">return</span></a></span><span> </span><span class="hs-special">[</span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716780"><span class="hs-identifier hs-var">pref</span></a></span><span> </span><span class="annot"><span class="annottext">String -&gt; String -&gt; String
</span><a href="../../filepath/src/System.FilePath.Windows.html#%3C%2F%3E"><span class="hs-operator hs-var">&lt;/&gt;</span></a></span><span> </span><span class="annot"><span class="annottext">ModuleName -&gt; String
</span><a href="Distribution.ModuleName.html#toFilePath"><span class="hs-identifier hs-var">ModuleName.toFilePath</span></a></span><span> </span><span class="annot"><span class="annottext">ModuleName
</span><a href="#local-6989586621679716762"><span class="hs-identifier hs-var">x</span></a></span><span> </span><span class="annot"><span class="annottext">String -&gt; String -&gt; String
</span><a href="../../filepath/src/System.FilePath.Windows.html#%3C.%3E"><span class="hs-operator hs-var">&lt;.&gt;</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716779"><span class="hs-identifier hs-var">wanted_obj_ext</span></a></span><span>
</span><span id="line-523"></span><span>               </span><span class="hs-glyph">|</span><span> </span><span id="local-6989586621679716762"><span class="annot"><span class="annottext">ModuleName
</span><a href="#local-6989586621679716762"><span class="hs-identifier hs-var">x</span></a></span></span><span> </span><span class="hs-glyph">&lt;-</span><span> </span><span class="annot"><span class="annottext">Library -&gt; ComponentLocalBuildInfo -&gt; [ModuleName]
</span><a href="Distribution.Simple.LocalBuildInfo.html#allLibModules"><span class="hs-identifier hs-var">allLibModules</span></a></span><span> </span><span class="annot"><span class="annottext">Library
</span><a href="#local-6989586621679716783"><span class="hs-identifier hs-var">lib</span></a></span><span> </span><span class="annot"><span class="annottext">ComponentLocalBuildInfo
</span><a href="#local-6989586621679716781"><span class="hs-identifier hs-var">clbi</span></a></span><span> </span><span class="hs-special">]</span><span>
</span><span id="line-524"></span><span>
</span><span id="line-525"></span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#mkGhcOptPackages"><span class="hs-identifier hs-type">mkGhcOptPackages</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="Distribution.Types.ComponentLocalBuildInfo.html#ComponentLocalBuildInfo"><span class="hs-identifier hs-type">ComponentLocalBuildInfo</span></a></span><span>
</span><span id="line-526"></span><span>                 </span><span class="hs-glyph">-&gt;</span><span> </span><span class="hs-special">[</span><span class="hs-special">(</span><span class="annot"><a href="Distribution.Backpack.html#OpenUnitId"><span class="hs-identifier hs-type">OpenUnitId</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><a href="Distribution.Types.ModuleRenaming.html#ModuleRenaming"><span class="hs-identifier hs-type">ModuleRenaming</span></a></span><span class="hs-special">)</span><span class="hs-special">]</span><span>
</span><span id="line-527"></span><span id="mkGhcOptPackages"><span class="annot"><span class="annottext">mkGhcOptPackages :: ComponentLocalBuildInfo -&gt; [(OpenUnitId, ModuleRenaming)]
</span><a href="Distribution.Simple.GHC.Internal.html#mkGhcOptPackages"><span class="hs-identifier hs-var hs-var">mkGhcOptPackages</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">ComponentLocalBuildInfo -&gt; [(OpenUnitId, ModuleRenaming)]
</span><a href="Distribution.Types.ComponentLocalBuildInfo.html#componentIncludes"><span class="hs-identifier hs-var hs-var">componentIncludes</span></a></span><span>
</span><span id="line-528"></span><span>
</span><span id="line-529"></span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#substTopDir"><span class="hs-identifier hs-type">substTopDir</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="../../base/src/GHC.IO.html#FilePath"><span class="hs-identifier hs-type">FilePath</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="Distribution.Types.InstalledPackageInfo.html#InstalledPackageInfo"><span class="hs-identifier hs-type">IPI.InstalledPackageInfo</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="Distribution.Types.InstalledPackageInfo.html#InstalledPackageInfo"><span class="hs-identifier hs-type">IPI.InstalledPackageInfo</span></a></span><span>
</span><span id="line-530"></span><span id="substTopDir"><span class="annot"><span class="annottext">substTopDir :: String -&gt; InstalledPackageInfo -&gt; InstalledPackageInfo
</span><a href="Distribution.Simple.GHC.Internal.html#substTopDir"><span class="hs-identifier hs-var hs-var">substTopDir</span></a></span></span><span> </span><span id="local-6989586621679716760"><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716760"><span class="hs-identifier hs-var">topDir</span></a></span></span><span> </span><span id="local-6989586621679716759"><span class="annot"><span class="annottext">InstalledPackageInfo
</span><a href="#local-6989586621679716759"><span class="hs-identifier hs-var">ipo</span></a></span></span><span>
</span><span id="line-531"></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">InstalledPackageInfo
</span><a href="#local-6989586621679716759"><span class="hs-identifier hs-var">ipo</span></a></span><span> </span><span class="hs-special">{</span><span>
</span><span id="line-532"></span><span>       </span><span class="annot"><span class="annottext">importDirs :: [String]
</span><a href="Distribution.Types.InstalledPackageInfo.html#importDirs"><span class="hs-identifier hs-var">IPI.importDirs</span></a></span><span>        </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">(String -&gt; String) -&gt; [String] -&gt; [String]
forall a b. (a -&gt; b) -&gt; [a] -&gt; [b]
</span><a href="../../base/src/GHC.Base.html#map"><span class="hs-identifier hs-var">map</span></a></span><span> </span><span class="annot"><span class="annottext">String -&gt; String
</span><a href="#local-6989586621679716757"><span class="hs-identifier hs-var">f</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">InstalledPackageInfo -&gt; [String]
</span><a href="Distribution.Types.InstalledPackageInfo.html#importDirs"><span class="hs-identifier hs-var hs-var">IPI.importDirs</span></a></span><span> </span><span class="annot"><span class="annottext">InstalledPackageInfo
</span><a href="#local-6989586621679716759"><span class="hs-identifier hs-var">ipo</span></a></span><span class="hs-special">)</span><span class="hs-special">,</span><span>
</span><span id="line-533"></span><span>       </span><span class="annot"><span class="annottext">libraryDirs :: [String]
</span><a href="Distribution.Types.InstalledPackageInfo.html#libraryDirs"><span class="hs-identifier hs-var">IPI.libraryDirs</span></a></span><span>       </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">(String -&gt; String) -&gt; [String] -&gt; [String]
forall a b. (a -&gt; b) -&gt; [a] -&gt; [b]
</span><a href="../../base/src/GHC.Base.html#map"><span class="hs-identifier hs-var">map</span></a></span><span> </span><span class="annot"><span class="annottext">String -&gt; String
</span><a href="#local-6989586621679716757"><span class="hs-identifier hs-var">f</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">InstalledPackageInfo -&gt; [String]
</span><a href="Distribution.Types.InstalledPackageInfo.html#libraryDirs"><span class="hs-identifier hs-var hs-var">IPI.libraryDirs</span></a></span><span> </span><span class="annot"><span class="annottext">InstalledPackageInfo
</span><a href="#local-6989586621679716759"><span class="hs-identifier hs-var">ipo</span></a></span><span class="hs-special">)</span><span class="hs-special">,</span><span>
</span><span id="line-534"></span><span>       </span><span class="annot"><span class="annottext">includeDirs :: [String]
</span><a href="Distribution.Types.InstalledPackageInfo.html#includeDirs"><span class="hs-identifier hs-var">IPI.includeDirs</span></a></span><span>       </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">(String -&gt; String) -&gt; [String] -&gt; [String]
forall a b. (a -&gt; b) -&gt; [a] -&gt; [b]
</span><a href="../../base/src/GHC.Base.html#map"><span class="hs-identifier hs-var">map</span></a></span><span> </span><span class="annot"><span class="annottext">String -&gt; String
</span><a href="#local-6989586621679716757"><span class="hs-identifier hs-var">f</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">InstalledPackageInfo -&gt; [String]
</span><a href="Distribution.Types.InstalledPackageInfo.html#includeDirs"><span class="hs-identifier hs-var hs-var">IPI.includeDirs</span></a></span><span> </span><span class="annot"><span class="annottext">InstalledPackageInfo
</span><a href="#local-6989586621679716759"><span class="hs-identifier hs-var">ipo</span></a></span><span class="hs-special">)</span><span class="hs-special">,</span><span>
</span><span id="line-535"></span><span>       </span><span class="annot"><span class="annottext">frameworkDirs :: [String]
</span><a href="Distribution.Types.InstalledPackageInfo.html#frameworkDirs"><span class="hs-identifier hs-var">IPI.frameworkDirs</span></a></span><span>     </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">(String -&gt; String) -&gt; [String] -&gt; [String]
forall a b. (a -&gt; b) -&gt; [a] -&gt; [b]
</span><a href="../../base/src/GHC.Base.html#map"><span class="hs-identifier hs-var">map</span></a></span><span> </span><span class="annot"><span class="annottext">String -&gt; String
</span><a href="#local-6989586621679716757"><span class="hs-identifier hs-var">f</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">InstalledPackageInfo -&gt; [String]
</span><a href="Distribution.Types.InstalledPackageInfo.html#frameworkDirs"><span class="hs-identifier hs-var hs-var">IPI.frameworkDirs</span></a></span><span> </span><span class="annot"><span class="annottext">InstalledPackageInfo
</span><a href="#local-6989586621679716759"><span class="hs-identifier hs-var">ipo</span></a></span><span class="hs-special">)</span><span class="hs-special">,</span><span>
</span><span id="line-536"></span><span>       </span><span class="annot"><span class="annottext">haddockInterfaces :: [String]
</span><a href="Distribution.Types.InstalledPackageInfo.html#haddockInterfaces"><span class="hs-identifier hs-var">IPI.haddockInterfaces</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">(String -&gt; String) -&gt; [String] -&gt; [String]
forall a b. (a -&gt; b) -&gt; [a] -&gt; [b]
</span><a href="../../base/src/GHC.Base.html#map"><span class="hs-identifier hs-var">map</span></a></span><span> </span><span class="annot"><span class="annottext">String -&gt; String
</span><a href="#local-6989586621679716757"><span class="hs-identifier hs-var">f</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">InstalledPackageInfo -&gt; [String]
</span><a href="Distribution.Types.InstalledPackageInfo.html#haddockInterfaces"><span class="hs-identifier hs-var hs-var">IPI.haddockInterfaces</span></a></span><span> </span><span class="annot"><span class="annottext">InstalledPackageInfo
</span><a href="#local-6989586621679716759"><span class="hs-identifier hs-var">ipo</span></a></span><span class="hs-special">)</span><span class="hs-special">,</span><span>
</span><span id="line-537"></span><span>       </span><span class="annot"><span class="annottext">haddockHTMLs :: [String]
</span><a href="Distribution.Types.InstalledPackageInfo.html#haddockHTMLs"><span class="hs-identifier hs-var">IPI.haddockHTMLs</span></a></span><span>      </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">(String -&gt; String) -&gt; [String] -&gt; [String]
forall a b. (a -&gt; b) -&gt; [a] -&gt; [b]
</span><a href="../../base/src/GHC.Base.html#map"><span class="hs-identifier hs-var">map</span></a></span><span> </span><span class="annot"><span class="annottext">String -&gt; String
</span><a href="#local-6989586621679716757"><span class="hs-identifier hs-var">f</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">InstalledPackageInfo -&gt; [String]
</span><a href="Distribution.Types.InstalledPackageInfo.html#haddockHTMLs"><span class="hs-identifier hs-var hs-var">IPI.haddockHTMLs</span></a></span><span> </span><span class="annot"><span class="annottext">InstalledPackageInfo
</span><a href="#local-6989586621679716759"><span class="hs-identifier hs-var">ipo</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-538"></span><span>   </span><span class="hs-special">}</span><span>
</span><span id="line-539"></span><span>    </span><span class="hs-keyword">where</span><span> </span><span id="local-6989586621679716757"><span class="annot"><span class="annottext">f :: String -&gt; String
</span><a href="#local-6989586621679716757"><span class="hs-identifier hs-var hs-var">f</span></a></span></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">Char
</span><span class="hs-char">'$'</span></span><span class="annot"><span class="hs-glyph hs-type">:</span></span><span class="annot"><span class="annottext">Char
</span><span class="hs-char">'t'</span></span><span class="annot"><span class="hs-glyph hs-type">:</span></span><span class="annot"><span class="annottext">Char
</span><span class="hs-char">'o'</span></span><span class="annot"><span class="hs-glyph hs-type">:</span></span><span class="annot"><span class="annottext">Char
</span><span class="hs-char">'p'</span></span><span class="annot"><span class="hs-glyph hs-type">:</span></span><span class="annot"><span class="annottext">Char
</span><span class="hs-char">'d'</span></span><span class="annot"><span class="hs-glyph hs-type">:</span></span><span class="annot"><span class="annottext">Char
</span><span class="hs-char">'i'</span></span><span class="annot"><span class="hs-glyph hs-type">:</span></span><span class="annot"><span class="annottext">Char
</span><span class="hs-char">'r'</span></span><span class="annot"><span class="hs-glyph hs-type">:</span></span><span id="local-6989586621679716751"><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716751"><span class="hs-identifier hs-var">rest</span></a></span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716760"><span class="hs-identifier hs-var">topDir</span></a></span><span> </span><span class="annot"><span class="annottext">String -&gt; String -&gt; String
forall a. [a] -&gt; [a] -&gt; [a]
</span><a href="../../base/src/GHC.Base.html#%2B%2B"><span class="hs-operator hs-var">++</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716751"><span class="hs-identifier hs-var">rest</span></a></span><span>
</span><span id="line-540"></span><span>          </span><span class="annot"><a href="#local-6989586621679716757"><span class="hs-identifier hs-var">f</span></a></span><span> </span><span id="local-6989586621679716750"><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716750"><span class="hs-identifier hs-var">x</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716750"><span class="hs-identifier hs-var">x</span></a></span><span>
</span><span id="line-541"></span><span>
</span><span id="line-542"></span><span class="hs-comment">-- Cabal does not use the environment variable GHC{,JS}_PACKAGE_PATH; let</span><span>
</span><span id="line-543"></span><span class="hs-comment">-- users know that this is the case. See ticket #335. Simply ignoring it is</span><span>
</span><span id="line-544"></span><span class="hs-comment">-- not a good idea, since then ghc and cabal are looking at different sets</span><span>
</span><span id="line-545"></span><span class="hs-comment">-- of package DBs and chaos is likely to ensue.</span><span>
</span><span id="line-546"></span><span class="hs-comment">--</span><span>
</span><span id="line-547"></span><span class="hs-comment">-- An exception to this is when running cabal from within a `cabal exec`</span><span>
</span><span id="line-548"></span><span class="hs-comment">-- environment. In this case, `cabal exec` will set the</span><span>
</span><span id="line-549"></span><span class="hs-comment">-- CABAL_SANDBOX_PACKAGE_PATH to the same value that it set</span><span>
</span><span id="line-550"></span><span class="hs-comment">-- GHC{,JS}_PACKAGE_PATH to. If that is the case it is OK to allow</span><span>
</span><span id="line-551"></span><span class="hs-comment">-- GHC{,JS}_PACKAGE_PATH.</span><span>
</span><span id="line-552"></span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#checkPackageDbEnvVar"><span class="hs-identifier hs-type">checkPackageDbEnvVar</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="Distribution.Verbosity.html#Verbosity"><span class="hs-identifier hs-type">Verbosity</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="../../base/src/GHC.Base.html#String"><span class="hs-identifier hs-type">String</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="../../base/src/GHC.Base.html#String"><span class="hs-identifier hs-type">String</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="hs-identifier hs-type">IO</span></span><span> </span><span class="hs-special">(</span><span class="hs-special">)</span><span>
</span><span id="line-553"></span><span id="checkPackageDbEnvVar"><span class="annot"><span class="annottext">checkPackageDbEnvVar :: Verbosity -&gt; String -&gt; String -&gt; IO ()
</span><a href="Distribution.Simple.GHC.Internal.html#checkPackageDbEnvVar"><span class="hs-identifier hs-var hs-var">checkPackageDbEnvVar</span></a></span></span><span> </span><span id="local-6989586621679716749"><span class="annot"><span class="annottext">Verbosity
</span><a href="#local-6989586621679716749"><span class="hs-identifier hs-var">verbosity</span></a></span></span><span> </span><span id="local-6989586621679716748"><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716748"><span class="hs-identifier hs-var">compilerName</span></a></span></span><span> </span><span id="local-6989586621679716747"><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716747"><span class="hs-identifier hs-var">packagePathEnvVar</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="hs-keyword">do</span><span>
</span><span id="line-554"></span><span>    </span><span id="local-6989586621679716746"><span class="annot"><span class="annottext">Maybe String
</span><a href="#local-6989586621679716746"><span class="hs-identifier hs-var">mPP</span></a></span></span><span> </span><span class="hs-glyph">&lt;-</span><span> </span><span class="annot"><span class="annottext">String -&gt; IO (Maybe String)
</span><a href="#local-6989586621679716745"><span class="hs-identifier hs-var">lookupEnv</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716747"><span class="hs-identifier hs-var">packagePathEnvVar</span></a></span><span>
</span><span id="line-555"></span><span>    </span><span class="annot"><span class="annottext">Bool -&gt; IO () -&gt; IO ()
forall (f :: * -&gt; *). Applicative f =&gt; Bool -&gt; f () -&gt; f ()
</span><a href="../../base/src/GHC.Base.html#when"><span class="hs-identifier hs-var">when</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">Maybe String -&gt; Bool
forall a. Maybe a -&gt; Bool
</span><a href="../../base/src/Data.Maybe.html#isJust"><span class="hs-identifier hs-var">isJust</span></a></span><span> </span><span class="annot"><span class="annottext">Maybe String
</span><a href="#local-6989586621679716746"><span class="hs-identifier hs-var">mPP</span></a></span><span class="hs-special">)</span><span> </span><span class="annot"><span class="annottext">(IO () -&gt; IO ()) -&gt; IO () -&gt; IO ()
forall a b. (a -&gt; b) -&gt; a -&gt; b
</span><a href="../../base/src/GHC.Base.html#%24"><span class="hs-operator hs-var">$</span></a></span><span> </span><span class="hs-keyword">do</span><span>
</span><span id="line-556"></span><span>        </span><span id="local-6989586621679716742"><span class="annot"><span class="annottext">Maybe String
</span><a href="#local-6989586621679716742"><span class="hs-identifier hs-var">mcsPP</span></a></span></span><span> </span><span class="hs-glyph">&lt;-</span><span> </span><span class="annot"><span class="annottext">String -&gt; IO (Maybe String)
</span><a href="#local-6989586621679716745"><span class="hs-identifier hs-var">lookupEnv</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;CABAL_SANDBOX_PACKAGE_PATH&quot;</span></span><span>
</span><span id="line-557"></span><span>        </span><span class="annot"><span class="annottext">Bool -&gt; IO () -&gt; IO ()
forall (f :: * -&gt; *). Applicative f =&gt; Bool -&gt; f () -&gt; f ()
</span><a href="../../base/src/Control.Monad.html#unless"><span class="hs-identifier hs-var">unless</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">Maybe String
</span><a href="#local-6989586621679716746"><span class="hs-identifier hs-var">mPP</span></a></span><span> </span><span class="annot"><span class="annottext">Maybe String -&gt; Maybe String -&gt; Bool
forall a. Eq a =&gt; a -&gt; a -&gt; Bool
</span><span class="hs-operator hs-var">==</span></span><span> </span><span class="annot"><span class="annottext">Maybe String
</span><a href="#local-6989586621679716742"><span class="hs-identifier hs-var">mcsPP</span></a></span><span class="hs-special">)</span><span> </span><span class="annot"><span class="annottext">IO ()
forall {a}. IO a
</span><a href="#local-6989586621679716740"><span class="hs-identifier hs-var">abort</span></a></span><span>
</span><span id="line-558"></span><span>    </span><span class="hs-keyword">where</span><span>
</span><span id="line-559"></span><span>        </span><span class="annot"><a href="#local-6989586621679716745"><span class="hs-identifier hs-type">lookupEnv</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="../../base/src/GHC.Base.html#String"><span class="hs-identifier hs-type">String</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="hs-identifier hs-type">IO</span></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="../../base/src/GHC.Maybe.html#Maybe"><span class="hs-identifier hs-type">Maybe</span></a></span><span> </span><span class="annot"><a href="../../base/src/GHC.Base.html#String"><span class="hs-identifier hs-type">String</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-560"></span><span>        </span><span id="local-6989586621679716745"><span class="annot"><span class="annottext">lookupEnv :: String -&gt; IO (Maybe String)
</span><a href="#local-6989586621679716745"><span class="hs-identifier hs-var hs-var">lookupEnv</span></a></span></span><span> </span><span id="local-6989586621679716739"><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716739"><span class="hs-identifier hs-var">name</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">String -&gt; Maybe String
forall a. a -&gt; Maybe a
</span><a href="../../base/src/GHC.Maybe.html#Just"><span class="hs-identifier hs-var">Just</span></a></span><span> </span><span class="annot"><span class="annottext">(String -&gt; Maybe String) -&gt; IO String -&gt; IO (Maybe String)
forall (f :: * -&gt; *) a b. Functor f =&gt; (a -&gt; b) -&gt; f a -&gt; f b
</span><a href="../../base/src/GHC.Base.html#fmap"><span class="hs-operator hs-var">`fmap`</span></a></span><span> </span><span class="annot"><span class="annottext">String -&gt; IO String
</span><a href="../../base/src/System.Environment.html#getEnv"><span class="hs-identifier hs-var">getEnv</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716739"><span class="hs-identifier hs-var">name</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-561"></span><span>                         </span><span class="annot"><span class="annottext">IO (Maybe String)
-&gt; (IOException -&gt; IO (Maybe String)) -&gt; IO (Maybe String)
forall a. IO a -&gt; (IOException -&gt; IO a) -&gt; IO a
</span><a href="Distribution.Compat.Exception.html#catchIO"><span class="hs-operator hs-var">`catchIO`</span></a></span><span> </span><span class="annot"><span class="annottext">IO (Maybe String) -&gt; IOException -&gt; IO (Maybe String)
forall a b. a -&gt; b -&gt; a
</span><a href="../../base/src/GHC.Base.html#const"><span class="hs-identifier hs-var">const</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">Maybe String -&gt; IO (Maybe String)
forall (m :: * -&gt; *) a. Monad m =&gt; a -&gt; m a
</span><a href="../../base/src/GHC.Base.html#return"><span class="hs-identifier hs-var">return</span></a></span><span> </span><span class="annot"><span class="annottext">Maybe String
forall a. Maybe a
</span><a href="../../base/src/GHC.Maybe.html#Nothing"><span class="hs-identifier hs-var">Nothing</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-562"></span><span>        </span><span id="local-6989586621679716740"><span class="annot"><span class="annottext">abort :: IO a
</span><a href="#local-6989586621679716740"><span class="hs-identifier hs-var hs-var">abort</span></a></span></span><span> </span><span class="hs-glyph">=</span><span>
</span><span id="line-563"></span><span>            </span><span class="annot"><span class="annottext">Verbosity -&gt; String -&gt; IO a
forall a. Verbosity -&gt; String -&gt; IO a
</span><a href="Distribution.Simple.Utils.html#die%27"><span class="hs-identifier hs-var">die'</span></a></span><span> </span><span class="annot"><span class="annottext">Verbosity
</span><a href="#local-6989586621679716749"><span class="hs-identifier hs-var">verbosity</span></a></span><span> </span><span class="annot"><span class="annottext">(String -&gt; IO a) -&gt; String -&gt; IO a
forall a b. (a -&gt; b) -&gt; a -&gt; b
</span><a href="../../base/src/GHC.Base.html#%24"><span class="hs-operator hs-var">$</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;Use of &quot;</span></span><span> </span><span class="annot"><span class="annottext">String -&gt; String -&gt; String
forall a. [a] -&gt; [a] -&gt; [a]
</span><a href="../../base/src/GHC.Base.html#%2B%2B"><span class="hs-operator hs-var">++</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716748"><span class="hs-identifier hs-var">compilerName</span></a></span><span> </span><span class="annot"><span class="annottext">String -&gt; String -&gt; String
forall a. [a] -&gt; [a] -&gt; [a]
</span><a href="../../base/src/GHC.Base.html#%2B%2B"><span class="hs-operator hs-var">++</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;'s environment variable &quot;</span></span><span>
</span><span id="line-564"></span><span>               </span><span class="annot"><span class="annottext">String -&gt; String -&gt; String
forall a. [a] -&gt; [a] -&gt; [a]
</span><a href="../../base/src/GHC.Base.html#%2B%2B"><span class="hs-operator hs-var">++</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716747"><span class="hs-identifier hs-var">packagePathEnvVar</span></a></span><span> </span><span class="annot"><span class="annottext">String -&gt; String -&gt; String
forall a. [a] -&gt; [a] -&gt; [a]
</span><a href="../../base/src/GHC.Base.html#%2B%2B"><span class="hs-operator hs-var">++</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot; is incompatible with Cabal. Use the &quot;</span></span><span>
</span><span id="line-565"></span><span>               </span><span class="annot"><span class="annottext">String -&gt; String -&gt; String
forall a. [a] -&gt; [a] -&gt; [a]
</span><a href="../../base/src/GHC.Base.html#%2B%2B"><span class="hs-operator hs-var">++</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;flag --package-db to specify a package database (it can be &quot;</span></span><span>
</span><span id="line-566"></span><span>               </span><span class="annot"><span class="annottext">String -&gt; String -&gt; String
forall a. [a] -&gt; [a] -&gt; [a]
</span><a href="../../base/src/GHC.Base.html#%2B%2B"><span class="hs-operator hs-var">++</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;used multiple times).&quot;</span></span><span>
</span><span id="line-567"></span><span>
</span><span id="line-568"></span><span>        </span><span class="annot"><span class="annottext">CallStack
</span><span class="hs-identifier">_</span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">CallStack
HasCallStack =&gt; CallStack
</span><a href="../../base/src/GHC.Stack.html#callStack"><span class="hs-identifier hs-var">callStack</span></a></span><span> </span><span class="hs-comment">-- TODO: output stack when erroring</span><span>
</span><span id="line-569"></span><span>
</span><span id="line-570"></span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#profDetailLevelFlag"><span class="hs-identifier hs-type">profDetailLevelFlag</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><span class="hs-identifier hs-type">Bool</span></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="Distribution.Simple.Compiler.html#ProfDetailLevel"><span class="hs-identifier hs-type">ProfDetailLevel</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="Distribution.Simple.Flag.html#Flag"><span class="hs-identifier hs-type">Flag</span></a></span><span> </span><span class="annot"><a href="Distribution.Simple.Program.GHC.html#GhcProfAuto"><span class="hs-identifier hs-type">GhcProfAuto</span></a></span><span>
</span><span id="line-571"></span><span id="profDetailLevelFlag"><span class="annot"><span class="annottext">profDetailLevelFlag :: Bool -&gt; ProfDetailLevel -&gt; Flag GhcProfAuto
</span><a href="Distribution.Simple.GHC.Internal.html#profDetailLevelFlag"><span class="hs-identifier hs-var hs-var">profDetailLevelFlag</span></a></span></span><span> </span><span id="local-6989586621679716734"><span class="annot"><span class="annottext">Bool
</span><a href="#local-6989586621679716734"><span class="hs-identifier hs-var">forLib</span></a></span></span><span> </span><span id="local-6989586621679716733"><span class="annot"><span class="annottext">ProfDetailLevel
</span><a href="#local-6989586621679716733"><span class="hs-identifier hs-var">mpl</span></a></span></span><span> </span><span class="hs-glyph">=</span><span>
</span><span id="line-572"></span><span>    </span><span class="hs-keyword">case</span><span> </span><span class="annot"><span class="annottext">ProfDetailLevel
</span><a href="#local-6989586621679716733"><span class="hs-identifier hs-var">mpl</span></a></span><span> </span><span class="hs-keyword">of</span><span>
</span><span id="line-573"></span><span>      </span><span class="annot"><span class="annottext">ProfDetailLevel
</span><a href="Distribution.Simple.Compiler.html#ProfDetailNone"><span class="hs-identifier hs-var">ProfDetailNone</span></a></span><span>                </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">Flag GhcProfAuto
forall a. Monoid a =&gt; a
</span><a href="../../base/src/GHC.Base.html#mempty"><span class="hs-identifier hs-var">mempty</span></a></span><span>
</span><span id="line-574"></span><span>      </span><span class="annot"><span class="annottext">ProfDetailLevel
</span><a href="Distribution.Simple.Compiler.html#ProfDetailDefault"><span class="hs-identifier hs-var">ProfDetailDefault</span></a></span><span> </span><span class="hs-glyph">|</span><span> </span><span class="annot"><span class="annottext">Bool
</span><a href="#local-6989586621679716734"><span class="hs-identifier hs-var">forLib</span></a></span><span>    </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">GhcProfAuto -&gt; Flag GhcProfAuto
forall a. a -&gt; Flag a
</span><a href="Distribution.Simple.Flag.html#toFlag"><span class="hs-identifier hs-var">toFlag</span></a></span><span> </span><span class="annot"><span class="annottext">GhcProfAuto
</span><a href="Distribution.Simple.Program.GHC.html#GhcProfAutoExported"><span class="hs-identifier hs-var">GhcProfAutoExported</span></a></span><span>
</span><span id="line-575"></span><span>                        </span><span class="hs-glyph">|</span><span> </span><span class="annot"><span class="annottext">Bool
</span><a href="../../base/src/GHC.Base.html#otherwise"><span class="hs-identifier hs-var">otherwise</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">GhcProfAuto -&gt; Flag GhcProfAuto
forall a. a -&gt; Flag a
</span><a href="Distribution.Simple.Flag.html#toFlag"><span class="hs-identifier hs-var">toFlag</span></a></span><span> </span><span class="annot"><span class="annottext">GhcProfAuto
</span><a href="Distribution.Simple.Program.GHC.html#GhcProfAutoToplevel"><span class="hs-identifier hs-var">GhcProfAutoToplevel</span></a></span><span>
</span><span id="line-576"></span><span>      </span><span class="annot"><span class="annottext">ProfDetailLevel
</span><a href="Distribution.Simple.Compiler.html#ProfDetailExportedFunctions"><span class="hs-identifier hs-var">ProfDetailExportedFunctions</span></a></span><span>   </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">GhcProfAuto -&gt; Flag GhcProfAuto
forall a. a -&gt; Flag a
</span><a href="Distribution.Simple.Flag.html#toFlag"><span class="hs-identifier hs-var">toFlag</span></a></span><span> </span><span class="annot"><span class="annottext">GhcProfAuto
</span><a href="Distribution.Simple.Program.GHC.html#GhcProfAutoExported"><span class="hs-identifier hs-var">GhcProfAutoExported</span></a></span><span>
</span><span id="line-577"></span><span>      </span><span class="annot"><span class="annottext">ProfDetailLevel
</span><a href="Distribution.Simple.Compiler.html#ProfDetailToplevelFunctions"><span class="hs-identifier hs-var">ProfDetailToplevelFunctions</span></a></span><span>   </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">GhcProfAuto -&gt; Flag GhcProfAuto
forall a. a -&gt; Flag a
</span><a href="Distribution.Simple.Flag.html#toFlag"><span class="hs-identifier hs-var">toFlag</span></a></span><span> </span><span class="annot"><span class="annottext">GhcProfAuto
</span><a href="Distribution.Simple.Program.GHC.html#GhcProfAutoToplevel"><span class="hs-identifier hs-var">GhcProfAutoToplevel</span></a></span><span>
</span><span id="line-578"></span><span>      </span><span class="annot"><span class="annottext">ProfDetailLevel
</span><a href="Distribution.Simple.Compiler.html#ProfDetailAllFunctions"><span class="hs-identifier hs-var">ProfDetailAllFunctions</span></a></span><span>        </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">GhcProfAuto -&gt; Flag GhcProfAuto
forall a. a -&gt; Flag a
</span><a href="Distribution.Simple.Flag.html#toFlag"><span class="hs-identifier hs-var">toFlag</span></a></span><span> </span><span class="annot"><span class="annottext">GhcProfAuto
</span><a href="Distribution.Simple.Program.GHC.html#GhcProfAutoAll"><span class="hs-identifier hs-var">GhcProfAutoAll</span></a></span><span>
</span><span id="line-579"></span><span>      </span><span class="annot"><a href="Distribution.Simple.Compiler.html#ProfDetailOther"><span class="hs-identifier hs-type">ProfDetailOther</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-identifier">_</span></span><span>             </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">Flag GhcProfAuto
forall a. Monoid a =&gt; a
</span><a href="../../base/src/GHC.Base.html#mempty"><span class="hs-identifier hs-var">mempty</span></a></span><span>
</span><span id="line-580"></span><span>
</span><span id="line-581"></span><span>
</span><span id="line-582"></span><span class="hs-comment">-- -----------------------------------------------------------------------------</span><span>
</span><span id="line-583"></span><span class="hs-comment">-- GHC platform and version strings</span><span>
</span><span id="line-584"></span><span>
</span><span id="line-585"></span><span class="hs-comment">-- | GHC's rendering of its host or target 'Arch' as used in its platform</span><span>
</span><span id="line-586"></span><span class="hs-comment">-- strings and certain file locations (such as user package db location).</span><span>
</span><span id="line-587"></span><span class="hs-comment">--</span><span>
</span><span id="line-588"></span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#ghcArchString"><span class="hs-identifier hs-type">ghcArchString</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="Distribution.System.html#Arch"><span class="hs-identifier hs-type">Arch</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="../../base/src/GHC.Base.html#String"><span class="hs-identifier hs-type">String</span></a></span><span>
</span><span id="line-589"></span><span id="ghcArchString"><span class="annot"><span class="annottext">ghcArchString :: Arch -&gt; String
</span><a href="Distribution.Simple.GHC.Internal.html#ghcArchString"><span class="hs-identifier hs-var hs-var">ghcArchString</span></a></span></span><span> </span><span class="annot"><span class="annottext">Arch
</span><a href="Distribution.System.html#PPC"><span class="hs-identifier hs-var">PPC</span></a></span><span>   </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;powerpc&quot;</span></span><span>
</span><span id="line-590"></span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#ghcArchString"><span class="hs-identifier hs-var">ghcArchString</span></a></span><span> </span><span class="annot"><span class="annottext">Arch
</span><a href="Distribution.System.html#PPC64"><span class="hs-identifier hs-var">PPC64</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;powerpc64&quot;</span></span><span>
</span><span id="line-591"></span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#ghcArchString"><span class="hs-identifier hs-var">ghcArchString</span></a></span><span> </span><span id="local-6989586621679716721"><span class="annot"><span class="annottext">Arch
</span><a href="#local-6989586621679716721"><span class="hs-identifier hs-var">other</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Arch -&gt; String
forall a. Pretty a =&gt; a -&gt; String
</span><a href="Distribution.Pretty.html#prettyShow"><span class="hs-identifier hs-var">prettyShow</span></a></span><span> </span><span class="annot"><span class="annottext">Arch
</span><a href="#local-6989586621679716721"><span class="hs-identifier hs-var">other</span></a></span><span>
</span><span id="line-592"></span><span>
</span><span id="line-593"></span><span class="hs-comment">-- | GHC's rendering of its host or target 'OS' as used in its platform</span><span>
</span><span id="line-594"></span><span class="hs-comment">-- strings and certain file locations (such as user package db location).</span><span>
</span><span id="line-595"></span><span class="hs-comment">--</span><span>
</span><span id="line-596"></span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#ghcOsString"><span class="hs-identifier hs-type">ghcOsString</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="Distribution.System.html#OS"><span class="hs-identifier hs-type">OS</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="../../base/src/GHC.Base.html#String"><span class="hs-identifier hs-type">String</span></a></span><span>
</span><span id="line-597"></span><span id="ghcOsString"><span class="annot"><span class="annottext">ghcOsString :: OS -&gt; String
</span><a href="Distribution.Simple.GHC.Internal.html#ghcOsString"><span class="hs-identifier hs-var hs-var">ghcOsString</span></a></span></span><span> </span><span class="annot"><span class="annottext">OS
</span><a href="Distribution.System.html#Windows"><span class="hs-identifier hs-var">Windows</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;mingw32&quot;</span></span><span>
</span><span id="line-598"></span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#ghcOsString"><span class="hs-identifier hs-var">ghcOsString</span></a></span><span> </span><span class="annot"><span class="annottext">OS
</span><a href="Distribution.System.html#OSX"><span class="hs-identifier hs-var">OSX</span></a></span><span>     </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;darwin&quot;</span></span><span>
</span><span id="line-599"></span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#ghcOsString"><span class="hs-identifier hs-var">ghcOsString</span></a></span><span> </span><span class="annot"><span class="annottext">OS
</span><a href="Distribution.System.html#Solaris"><span class="hs-identifier hs-var">Solaris</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;solaris2&quot;</span></span><span>
</span><span id="line-600"></span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#ghcOsString"><span class="hs-identifier hs-var">ghcOsString</span></a></span><span> </span><span id="local-6989586621679716718"><span class="annot"><span class="annottext">OS
</span><a href="#local-6989586621679716718"><span class="hs-identifier hs-var">other</span></a></span></span><span>   </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">OS -&gt; String
forall a. Pretty a =&gt; a -&gt; String
</span><a href="Distribution.Pretty.html#prettyShow"><span class="hs-identifier hs-var">prettyShow</span></a></span><span> </span><span class="annot"><span class="annottext">OS
</span><a href="#local-6989586621679716718"><span class="hs-identifier hs-var">other</span></a></span><span>
</span><span id="line-601"></span><span>
</span><span id="line-602"></span><span class="hs-comment">-- | GHC's rendering of its platform and compiler version string as used in</span><span>
</span><span id="line-603"></span><span class="hs-comment">-- certain file locations (such as user package db location).</span><span>
</span><span id="line-604"></span><span class="hs-comment">-- For example @x86_64-linux-7.10.4@</span><span>
</span><span id="line-605"></span><span class="hs-comment">--</span><span>
</span><span id="line-606"></span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#ghcPlatformAndVersionString"><span class="hs-identifier hs-type">ghcPlatformAndVersionString</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="Distribution.System.html#Platform"><span class="hs-identifier hs-type">Platform</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="Distribution.Types.Version.html#Version"><span class="hs-identifier hs-type">Version</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="../../base/src/GHC.Base.html#String"><span class="hs-identifier hs-type">String</span></a></span><span>
</span><span id="line-607"></span><span id="ghcPlatformAndVersionString"><span class="annot"><span class="annottext">ghcPlatformAndVersionString :: Platform -&gt; Version -&gt; String
</span><a href="Distribution.Simple.GHC.Internal.html#ghcPlatformAndVersionString"><span class="hs-identifier hs-var hs-var">ghcPlatformAndVersionString</span></a></span></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="Distribution.System.html#Platform"><span class="hs-identifier hs-type">Platform</span></a></span><span> </span><span id="local-6989586621679716716"><span class="annot"><span class="annottext">Arch
</span><a href="#local-6989586621679716716"><span class="hs-identifier hs-var">arch</span></a></span></span><span> </span><span id="local-6989586621679716715"><span class="annot"><span class="annottext">OS
</span><a href="#local-6989586621679716715"><span class="hs-identifier hs-var">os</span></a></span></span><span class="hs-special">)</span><span> </span><span id="local-6989586621679716714"><span class="annot"><span class="annottext">Version
</span><a href="#local-6989586621679716714"><span class="hs-identifier hs-var">version</span></a></span></span><span> </span><span class="hs-glyph">=</span><span>
</span><span id="line-608"></span><span>    </span><span class="annot"><span class="annottext">String -&gt; [String] -&gt; String
forall a. [a] -&gt; [[a]] -&gt; [a]
</span><a href="../../base/src/Data.OldList.html#intercalate"><span class="hs-identifier hs-var">intercalate</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;-&quot;</span></span><span> </span><span class="hs-special">[</span><span> </span><span class="annot"><span class="annottext">Arch -&gt; String
</span><a href="Distribution.Simple.GHC.Internal.html#ghcArchString"><span class="hs-identifier hs-var">ghcArchString</span></a></span><span> </span><span class="annot"><span class="annottext">Arch
</span><a href="#local-6989586621679716716"><span class="hs-identifier hs-var">arch</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><span class="annottext">OS -&gt; String
</span><a href="Distribution.Simple.GHC.Internal.html#ghcOsString"><span class="hs-identifier hs-var">ghcOsString</span></a></span><span> </span><span class="annot"><span class="annottext">OS
</span><a href="#local-6989586621679716715"><span class="hs-identifier hs-var">os</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><span class="annottext">Version -&gt; String
forall a. Pretty a =&gt; a -&gt; String
</span><a href="Distribution.Pretty.html#prettyShow"><span class="hs-identifier hs-var">prettyShow</span></a></span><span> </span><span class="annot"><span class="annottext">Version
</span><a href="#local-6989586621679716714"><span class="hs-identifier hs-var">version</span></a></span><span> </span><span class="hs-special">]</span><span>
</span><span id="line-609"></span><span>
</span><span id="line-610"></span><span>
</span><span id="line-611"></span><span class="hs-comment">-- -----------------------------------------------------------------------------</span><span>
</span><span id="line-612"></span><span class="hs-comment">-- Constructing GHC environment files</span><span>
</span><span id="line-613"></span><span>
</span><span id="line-614"></span><span class="hs-comment">-- | The kinds of entries we can stick in a @.ghc.environment@ file.</span><span>
</span><span id="line-615"></span><span class="hs-comment">--</span><span>
</span><span id="line-616"></span><span class="hs-keyword">data</span><span> </span><span id="GhcEnvironmentFileEntry"><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#GhcEnvironmentFileEntry"><span class="hs-identifier hs-var">GhcEnvironmentFileEntry</span></a></span></span><span> </span><span class="hs-glyph">=</span><span>
</span><span id="line-617"></span><span>       </span><span id="GhcEnvFileComment"><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#GhcEnvFileComment"><span class="hs-identifier hs-var">GhcEnvFileComment</span></a></span></span><span>   </span><span class="annot"><a href="../../base/src/GHC.Base.html#String"><span class="hs-identifier hs-type">String</span></a></span><span>     </span><span class="hs-comment">-- ^ @-- a comment@</span><span>
</span><span id="line-618"></span><span>     </span><span class="hs-glyph">|</span><span> </span><span id="GhcEnvFilePackageId"><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#GhcEnvFilePackageId"><span class="hs-identifier hs-var">GhcEnvFilePackageId</span></a></span></span><span> </span><span class="annot"><a href="Distribution.Types.UnitId.html#UnitId"><span class="hs-identifier hs-type">UnitId</span></a></span><span>     </span><span class="hs-comment">-- ^ @package-id foo-1.0-4fe301a...@</span><span>
</span><span id="line-619"></span><span>     </span><span class="hs-glyph">|</span><span> </span><span id="GhcEnvFilePackageDb"><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#GhcEnvFilePackageDb"><span class="hs-identifier hs-var">GhcEnvFilePackageDb</span></a></span></span><span> </span><span class="annot"><a href="Distribution.Simple.Compiler.html#PackageDB"><span class="hs-identifier hs-type">PackageDB</span></a></span><span>  </span><span class="hs-comment">-- ^ @global-package-db@,</span><span>
</span><span id="line-620"></span><span>                                      </span><span class="hs-comment">--   @user-package-db@ or</span><span>
</span><span id="line-621"></span><span>                                      </span><span class="hs-comment">--   @package-db blah/package.conf.d/@</span><span>
</span><span id="line-622"></span><span>     </span><span class="hs-glyph">|</span><span> </span><span id="GhcEnvFileClearPackageDbStack"><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#GhcEnvFileClearPackageDbStack"><span class="hs-identifier hs-var">GhcEnvFileClearPackageDbStack</span></a></span></span><span>  </span><span class="hs-comment">-- ^ @clear-package-db@</span><span>
</span><span id="line-623"></span><span>     </span><span class="hs-keyword">deriving</span><span> </span><span class="hs-special">(</span><span id="local-6989586621679716700"><span id="local-6989586621679716707"><span class="annot"><span class="annottext">GhcEnvironmentFileEntry -&gt; GhcEnvironmentFileEntry -&gt; Bool
(GhcEnvironmentFileEntry -&gt; GhcEnvironmentFileEntry -&gt; Bool)
-&gt; (GhcEnvironmentFileEntry -&gt; GhcEnvironmentFileEntry -&gt; Bool)
-&gt; Eq GhcEnvironmentFileEntry
forall a. (a -&gt; a -&gt; Bool) -&gt; (a -&gt; a -&gt; Bool) -&gt; Eq a
/= :: GhcEnvironmentFileEntry -&gt; GhcEnvironmentFileEntry -&gt; Bool
$c/= :: GhcEnvironmentFileEntry -&gt; GhcEnvironmentFileEntry -&gt; Bool
== :: GhcEnvironmentFileEntry -&gt; GhcEnvironmentFileEntry -&gt; Bool
$c== :: GhcEnvironmentFileEntry -&gt; GhcEnvironmentFileEntry -&gt; Bool
</span><span class="hs-identifier hs-var hs-var hs-var hs-var hs-var hs-var">Eq</span></span></span></span><span class="hs-special">,</span><span> </span><span id="local-6989586621679716678"><span id="local-6989586621679716680"><span id="local-6989586621679716682"><span id="local-6989586621679716684"><span id="local-6989586621679716686"><span id="local-6989586621679716688"><span id="local-6989586621679716695"><span class="annot"><span class="annottext">Eq GhcEnvironmentFileEntry
Eq GhcEnvironmentFileEntry
-&gt; (GhcEnvironmentFileEntry -&gt; GhcEnvironmentFileEntry -&gt; Ordering)
-&gt; (GhcEnvironmentFileEntry -&gt; GhcEnvironmentFileEntry -&gt; Bool)
-&gt; (GhcEnvironmentFileEntry -&gt; GhcEnvironmentFileEntry -&gt; Bool)
-&gt; (GhcEnvironmentFileEntry -&gt; GhcEnvironmentFileEntry -&gt; Bool)
-&gt; (GhcEnvironmentFileEntry -&gt; GhcEnvironmentFileEntry -&gt; Bool)
-&gt; (GhcEnvironmentFileEntry
    -&gt; GhcEnvironmentFileEntry -&gt; GhcEnvironmentFileEntry)
-&gt; (GhcEnvironmentFileEntry
    -&gt; GhcEnvironmentFileEntry -&gt; GhcEnvironmentFileEntry)
-&gt; Ord GhcEnvironmentFileEntry
GhcEnvironmentFileEntry -&gt; GhcEnvironmentFileEntry -&gt; Bool
GhcEnvironmentFileEntry -&gt; GhcEnvironmentFileEntry -&gt; Ordering
GhcEnvironmentFileEntry
-&gt; GhcEnvironmentFileEntry -&gt; GhcEnvironmentFileEntry
forall a.
Eq a
-&gt; (a -&gt; a -&gt; Ordering)
-&gt; (a -&gt; a -&gt; Bool)
-&gt; (a -&gt; a -&gt; Bool)
-&gt; (a -&gt; a -&gt; Bool)
-&gt; (a -&gt; a -&gt; Bool)
-&gt; (a -&gt; a -&gt; a)
-&gt; (a -&gt; a -&gt; a)
-&gt; Ord a
min :: GhcEnvironmentFileEntry
-&gt; GhcEnvironmentFileEntry -&gt; GhcEnvironmentFileEntry
$cmin :: GhcEnvironmentFileEntry
-&gt; GhcEnvironmentFileEntry -&gt; GhcEnvironmentFileEntry
max :: GhcEnvironmentFileEntry
-&gt; GhcEnvironmentFileEntry -&gt; GhcEnvironmentFileEntry
$cmax :: GhcEnvironmentFileEntry
-&gt; GhcEnvironmentFileEntry -&gt; GhcEnvironmentFileEntry
&gt;= :: GhcEnvironmentFileEntry -&gt; GhcEnvironmentFileEntry -&gt; Bool
$c&gt;= :: GhcEnvironmentFileEntry -&gt; GhcEnvironmentFileEntry -&gt; Bool
&gt; :: GhcEnvironmentFileEntry -&gt; GhcEnvironmentFileEntry -&gt; Bool
$c&gt; :: GhcEnvironmentFileEntry -&gt; GhcEnvironmentFileEntry -&gt; Bool
&lt;= :: GhcEnvironmentFileEntry -&gt; GhcEnvironmentFileEntry -&gt; Bool
$c&lt;= :: GhcEnvironmentFileEntry -&gt; GhcEnvironmentFileEntry -&gt; Bool
&lt; :: GhcEnvironmentFileEntry -&gt; GhcEnvironmentFileEntry -&gt; Bool
$c&lt; :: GhcEnvironmentFileEntry -&gt; GhcEnvironmentFileEntry -&gt; Bool
compare :: GhcEnvironmentFileEntry -&gt; GhcEnvironmentFileEntry -&gt; Ordering
$ccompare :: GhcEnvironmentFileEntry -&gt; GhcEnvironmentFileEntry -&gt; Ordering
</span><span class="hs-identifier hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var">Ord</span></span></span></span></span></span></span></span></span><span class="hs-special">,</span><span> </span><span id="local-6989586621679716660"><span id="local-6989586621679716662"><span id="local-6989586621679716675"><span class="annot"><span class="annottext">Int -&gt; GhcEnvironmentFileEntry -&gt; String -&gt; String
[GhcEnvironmentFileEntry] -&gt; String -&gt; String
GhcEnvironmentFileEntry -&gt; String
(Int -&gt; GhcEnvironmentFileEntry -&gt; String -&gt; String)
-&gt; (GhcEnvironmentFileEntry -&gt; String)
-&gt; ([GhcEnvironmentFileEntry] -&gt; String -&gt; String)
-&gt; Show GhcEnvironmentFileEntry
forall a.
(Int -&gt; a -&gt; String -&gt; String)
-&gt; (a -&gt; String) -&gt; ([a] -&gt; String -&gt; String) -&gt; Show a
showList :: [GhcEnvironmentFileEntry] -&gt; String -&gt; String
$cshowList :: [GhcEnvironmentFileEntry] -&gt; String -&gt; String
show :: GhcEnvironmentFileEntry -&gt; String
$cshow :: GhcEnvironmentFileEntry -&gt; String
showsPrec :: Int -&gt; GhcEnvironmentFileEntry -&gt; String -&gt; String
$cshowsPrec :: Int -&gt; GhcEnvironmentFileEntry -&gt; String -&gt; String
</span><a href="../../base/src/GHC.Show.html#Show"><span class="hs-identifier hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var">Show</span></a></span></span></span></span><span class="hs-special">)</span><span>
</span><span id="line-624"></span><span>
</span><span id="line-625"></span><span class="hs-comment">-- | Make entries for a GHC environment file based on a 'PackageDBStack' and</span><span>
</span><span id="line-626"></span><span class="hs-comment">-- a bunch of package (unit) ids.</span><span>
</span><span id="line-627"></span><span class="hs-comment">--</span><span>
</span><span id="line-628"></span><span class="hs-comment">-- If you need to do anything more complicated then either use this as a basis</span><span>
</span><span id="line-629"></span><span class="hs-comment">-- and add more entries, or just make all the entries directly.</span><span>
</span><span id="line-630"></span><span class="hs-comment">--</span><span>
</span><span id="line-631"></span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#simpleGhcEnvironmentFile"><span class="hs-identifier hs-type">simpleGhcEnvironmentFile</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="Distribution.Simple.Compiler.html#PackageDBStack"><span class="hs-identifier hs-type">PackageDBStack</span></a></span><span>
</span><span id="line-632"></span><span>                         </span><span class="hs-glyph">-&gt;</span><span> </span><span class="hs-special">[</span><span class="annot"><a href="Distribution.Types.UnitId.html#UnitId"><span class="hs-identifier hs-type">UnitId</span></a></span><span class="hs-special">]</span><span>
</span><span id="line-633"></span><span>                         </span><span class="hs-glyph">-&gt;</span><span> </span><span class="hs-special">[</span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#GhcEnvironmentFileEntry"><span class="hs-identifier hs-type">GhcEnvironmentFileEntry</span></a></span><span class="hs-special">]</span><span>
</span><span id="line-634"></span><span id="simpleGhcEnvironmentFile"><span class="annot"><span class="annottext">simpleGhcEnvironmentFile :: PackageDBStack -&gt; [UnitId] -&gt; [GhcEnvironmentFileEntry]
</span><a href="Distribution.Simple.GHC.Internal.html#simpleGhcEnvironmentFile"><span class="hs-identifier hs-var hs-var">simpleGhcEnvironmentFile</span></a></span></span><span> </span><span id="local-6989586621679716657"><span class="annot"><span class="annottext">PackageDBStack
</span><a href="#local-6989586621679716657"><span class="hs-identifier hs-var">packageDBs</span></a></span></span><span> </span><span id="local-6989586621679716656"><span class="annot"><span class="annottext">[UnitId]
</span><a href="#local-6989586621679716656"><span class="hs-identifier hs-var">pkgids</span></a></span></span><span> </span><span class="hs-glyph">=</span><span>
</span><span id="line-635"></span><span>    </span><span class="annot"><span class="annottext">GhcEnvironmentFileEntry
</span><a href="Distribution.Simple.GHC.Internal.html#GhcEnvFileClearPackageDbStack"><span class="hs-identifier hs-var">GhcEnvFileClearPackageDbStack</span></a></span><span>
</span><span id="line-636"></span><span>  </span><span class="annot"><span class="annottext">GhcEnvironmentFileEntry
-&gt; [GhcEnvironmentFileEntry] -&gt; [GhcEnvironmentFileEntry]
forall a. a -&gt; [a] -&gt; [a]
</span><span class="hs-glyph hs-var">:</span></span><span> </span><span class="annot"><span class="annottext">(PackageDB -&gt; GhcEnvironmentFileEntry)
-&gt; PackageDBStack -&gt; [GhcEnvironmentFileEntry]
forall a b. (a -&gt; b) -&gt; [a] -&gt; [b]
</span><a href="../../base/src/GHC.Base.html#map"><span class="hs-identifier hs-var">map</span></a></span><span> </span><span class="annot"><span class="annottext">PackageDB -&gt; GhcEnvironmentFileEntry
</span><a href="Distribution.Simple.GHC.Internal.html#GhcEnvFilePackageDb"><span class="hs-identifier hs-var">GhcEnvFilePackageDb</span></a></span><span> </span><span class="annot"><span class="annottext">PackageDBStack
</span><a href="#local-6989586621679716657"><span class="hs-identifier hs-var">packageDBs</span></a></span><span>
</span><span id="line-637"></span><span> </span><span class="annot"><span class="annottext">[GhcEnvironmentFileEntry]
-&gt; [GhcEnvironmentFileEntry] -&gt; [GhcEnvironmentFileEntry]
forall a. [a] -&gt; [a] -&gt; [a]
</span><a href="../../base/src/GHC.Base.html#%2B%2B"><span class="hs-operator hs-var">++</span></a></span><span> </span><span class="annot"><span class="annottext">(UnitId -&gt; GhcEnvironmentFileEntry)
-&gt; [UnitId] -&gt; [GhcEnvironmentFileEntry]
forall a b. (a -&gt; b) -&gt; [a] -&gt; [b]
</span><a href="../../base/src/GHC.Base.html#map"><span class="hs-identifier hs-var">map</span></a></span><span> </span><span class="annot"><span class="annottext">UnitId -&gt; GhcEnvironmentFileEntry
</span><a href="Distribution.Simple.GHC.Internal.html#GhcEnvFilePackageId"><span class="hs-identifier hs-var">GhcEnvFilePackageId</span></a></span><span> </span><span class="annot"><span class="annottext">[UnitId]
</span><a href="#local-6989586621679716656"><span class="hs-identifier hs-var">pkgids</span></a></span><span>
</span><span id="line-638"></span><span>
</span><span id="line-639"></span><span class="hs-comment">-- | Write a @.ghc.environment-$arch-$os-$ver@ file in the given directory.</span><span>
</span><span id="line-640"></span><span class="hs-comment">--</span><span>
</span><span id="line-641"></span><span class="hs-comment">-- The 'Platform' and GHC 'Version' are needed as part of the file name.</span><span>
</span><span id="line-642"></span><span class="hs-comment">--</span><span>
</span><span id="line-643"></span><span class="hs-comment">-- Returns the name of the file written.</span><span>
</span><span id="line-644"></span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#writeGhcEnvironmentFile"><span class="hs-identifier hs-type">writeGhcEnvironmentFile</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="../../base/src/GHC.IO.html#FilePath"><span class="hs-identifier hs-type">FilePath</span></a></span><span>  </span><span class="hs-comment">-- ^ directory in which to put it</span><span>
</span><span id="line-645"></span><span>                        </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="Distribution.System.html#Platform"><span class="hs-identifier hs-type">Platform</span></a></span><span>  </span><span class="hs-comment">-- ^ the GHC target platform</span><span>
</span><span id="line-646"></span><span>                        </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="Distribution.Types.Version.html#Version"><span class="hs-identifier hs-type">Version</span></a></span><span>   </span><span class="hs-comment">-- ^ the GHC version</span><span>
</span><span id="line-647"></span><span>                        </span><span class="hs-glyph">-&gt;</span><span> </span><span class="hs-special">[</span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#GhcEnvironmentFileEntry"><span class="hs-identifier hs-type">GhcEnvironmentFileEntry</span></a></span><span class="hs-special">]</span><span> </span><span class="hs-comment">-- ^ the content</span><span>
</span><span id="line-648"></span><span>                        </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="hs-identifier hs-type">IO</span></span><span> </span><span class="annot"><a href="../../base/src/GHC.IO.html#FilePath"><span class="hs-identifier hs-type">FilePath</span></a></span><span>
</span><span id="line-649"></span><span id="writeGhcEnvironmentFile"><span class="annot"><span class="annottext">writeGhcEnvironmentFile :: String
-&gt; Platform -&gt; Version -&gt; [GhcEnvironmentFileEntry] -&gt; IO String
</span><a href="Distribution.Simple.GHC.Internal.html#writeGhcEnvironmentFile"><span class="hs-identifier hs-var hs-var">writeGhcEnvironmentFile</span></a></span></span><span> </span><span id="local-6989586621679716655"><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716655"><span class="hs-identifier hs-var">directory</span></a></span></span><span> </span><span id="local-6989586621679716654"><span class="annot"><span class="annottext">Platform
</span><a href="#local-6989586621679716654"><span class="hs-identifier hs-var">platform</span></a></span></span><span> </span><span id="local-6989586621679716653"><span class="annot"><span class="annottext">Version
</span><a href="#local-6989586621679716653"><span class="hs-identifier hs-var">ghcversion</span></a></span></span><span> </span><span id="local-6989586621679716652"><span class="annot"><span class="annottext">[GhcEnvironmentFileEntry]
</span><a href="#local-6989586621679716652"><span class="hs-identifier hs-var">entries</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="hs-keyword">do</span><span>
</span><span id="line-650"></span><span>    </span><span class="annot"><span class="annottext">String -&gt; ByteString -&gt; IO ()
</span><a href="Distribution.Utils.Generic.html#writeFileAtomic"><span class="hs-identifier hs-var">writeFileAtomic</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716650"><span class="hs-identifier hs-var">envfile</span></a></span><span> </span><span class="annot"><span class="annottext">(ByteString -&gt; IO ())
-&gt; ([GhcEnvironmentFileEntry] -&gt; ByteString)
-&gt; [GhcEnvironmentFileEntry]
-&gt; IO ()
forall b c a. (b -&gt; c) -&gt; (a -&gt; b) -&gt; a -&gt; c
</span><a href="../../base/src/GHC.Base.html#."><span class="hs-operator hs-var">.</span></a></span><span> </span><span class="annot"><span class="annottext">String -&gt; ByteString
</span><a href="../../bytestring/src/Data.ByteString.Lazy.Char8.html#pack"><span class="hs-identifier hs-var">BS.pack</span></a></span><span> </span><span class="annot"><span class="annottext">(String -&gt; ByteString)
-&gt; ([GhcEnvironmentFileEntry] -&gt; String)
-&gt; [GhcEnvironmentFileEntry]
-&gt; ByteString
forall b c a. (b -&gt; c) -&gt; (a -&gt; b) -&gt; a -&gt; c
</span><a href="../../base/src/GHC.Base.html#."><span class="hs-operator hs-var">.</span></a></span><span> </span><span class="annot"><span class="annottext">[GhcEnvironmentFileEntry] -&gt; String
</span><a href="Distribution.Simple.GHC.Internal.html#renderGhcEnvironmentFile"><span class="hs-identifier hs-var">renderGhcEnvironmentFile</span></a></span><span> </span><span class="annot"><span class="annottext">([GhcEnvironmentFileEntry] -&gt; IO ())
-&gt; [GhcEnvironmentFileEntry] -&gt; IO ()
forall a b. (a -&gt; b) -&gt; a -&gt; b
</span><a href="../../base/src/GHC.Base.html#%24"><span class="hs-operator hs-var">$</span></a></span><span> </span><span class="annot"><span class="annottext">[GhcEnvironmentFileEntry]
</span><a href="#local-6989586621679716652"><span class="hs-identifier hs-var">entries</span></a></span><span>
</span><span id="line-651"></span><span>    </span><span class="annot"><span class="annottext">String -&gt; IO String
forall (m :: * -&gt; *) a. Monad m =&gt; a -&gt; m a
</span><a href="../../base/src/GHC.Base.html#return"><span class="hs-identifier hs-var">return</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716650"><span class="hs-identifier hs-var">envfile</span></a></span><span>
</span><span id="line-652"></span><span>  </span><span class="hs-keyword">where</span><span>
</span><span id="line-653"></span><span>    </span><span id="local-6989586621679716650"><span class="annot"><span class="annottext">envfile :: String
</span><a href="#local-6989586621679716650"><span class="hs-identifier hs-var hs-var">envfile</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716655"><span class="hs-identifier hs-var">directory</span></a></span><span> </span><span class="annot"><span class="annottext">String -&gt; String -&gt; String
</span><a href="../../filepath/src/System.FilePath.Windows.html#%3C%2F%3E"><span class="hs-operator hs-var">&lt;/&gt;</span></a></span><span> </span><span class="annot"><span class="annottext">Platform -&gt; Version -&gt; String
</span><a href="Distribution.Simple.GHC.Internal.html#ghcEnvironmentFileName"><span class="hs-identifier hs-var">ghcEnvironmentFileName</span></a></span><span> </span><span class="annot"><span class="annottext">Platform
</span><a href="#local-6989586621679716654"><span class="hs-identifier hs-var">platform</span></a></span><span> </span><span class="annot"><span class="annottext">Version
</span><a href="#local-6989586621679716653"><span class="hs-identifier hs-var">ghcversion</span></a></span><span>
</span><span id="line-654"></span><span>
</span><span id="line-655"></span><span class="hs-comment">-- | The @.ghc.environment-$arch-$os-$ver@ file name</span><span>
</span><span id="line-656"></span><span class="hs-comment">--</span><span>
</span><span id="line-657"></span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#ghcEnvironmentFileName"><span class="hs-identifier hs-type">ghcEnvironmentFileName</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="Distribution.System.html#Platform"><span class="hs-identifier hs-type">Platform</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="Distribution.Types.Version.html#Version"><span class="hs-identifier hs-type">Version</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="../../base/src/GHC.IO.html#FilePath"><span class="hs-identifier hs-type">FilePath</span></a></span><span>
</span><span id="line-658"></span><span id="ghcEnvironmentFileName"><span class="annot"><span class="annottext">ghcEnvironmentFileName :: Platform -&gt; Version -&gt; String
</span><a href="Distribution.Simple.GHC.Internal.html#ghcEnvironmentFileName"><span class="hs-identifier hs-var hs-var">ghcEnvironmentFileName</span></a></span></span><span> </span><span id="local-6989586621679716648"><span class="annot"><span class="annottext">Platform
</span><a href="#local-6989586621679716648"><span class="hs-identifier hs-var">platform</span></a></span></span><span> </span><span id="local-6989586621679716647"><span class="annot"><span class="annottext">Version
</span><a href="#local-6989586621679716647"><span class="hs-identifier hs-var">ghcversion</span></a></span></span><span> </span><span class="hs-glyph">=</span><span>
</span><span id="line-659"></span><span>    </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;.ghc.environment.&quot;</span></span><span> </span><span class="annot"><span class="annottext">String -&gt; String -&gt; String
forall a. [a] -&gt; [a] -&gt; [a]
</span><a href="../../base/src/GHC.Base.html#%2B%2B"><span class="hs-operator hs-var">++</span></a></span><span> </span><span class="annot"><span class="annottext">Platform -&gt; Version -&gt; String
</span><a href="Distribution.Simple.GHC.Internal.html#ghcPlatformAndVersionString"><span class="hs-identifier hs-var">ghcPlatformAndVersionString</span></a></span><span> </span><span class="annot"><span class="annottext">Platform
</span><a href="#local-6989586621679716648"><span class="hs-identifier hs-var">platform</span></a></span><span> </span><span class="annot"><span class="annottext">Version
</span><a href="#local-6989586621679716647"><span class="hs-identifier hs-var">ghcversion</span></a></span><span>
</span><span id="line-660"></span><span>
</span><span id="line-661"></span><span class="hs-comment">-- | Render a bunch of GHC environment file entries</span><span>
</span><span id="line-662"></span><span class="hs-comment">--</span><span>
</span><span id="line-663"></span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#renderGhcEnvironmentFile"><span class="hs-identifier hs-type">renderGhcEnvironmentFile</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="hs-special">[</span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#GhcEnvironmentFileEntry"><span class="hs-identifier hs-type">GhcEnvironmentFileEntry</span></a></span><span class="hs-special">]</span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="../../base/src/GHC.Base.html#String"><span class="hs-identifier hs-type">String</span></a></span><span>
</span><span id="line-664"></span><span id="renderGhcEnvironmentFile"><span class="annot"><span class="annottext">renderGhcEnvironmentFile :: [GhcEnvironmentFileEntry] -&gt; String
</span><a href="Distribution.Simple.GHC.Internal.html#renderGhcEnvironmentFile"><span class="hs-identifier hs-var hs-var">renderGhcEnvironmentFile</span></a></span></span><span> </span><span class="hs-glyph">=</span><span>
</span><span id="line-665"></span><span>    </span><span class="annot"><span class="annottext">[String] -&gt; String
</span><a href="../../base/src/Data.OldList.html#unlines"><span class="hs-identifier hs-var">unlines</span></a></span><span> </span><span class="annot"><span class="annottext">([String] -&gt; String)
-&gt; ([GhcEnvironmentFileEntry] -&gt; [String])
-&gt; [GhcEnvironmentFileEntry]
-&gt; String
forall b c a. (b -&gt; c) -&gt; (a -&gt; b) -&gt; a -&gt; c
</span><a href="../../base/src/GHC.Base.html#."><span class="hs-operator hs-var">.</span></a></span><span> </span><span class="annot"><span class="annottext">(GhcEnvironmentFileEntry -&gt; String)
-&gt; [GhcEnvironmentFileEntry] -&gt; [String]
forall a b. (a -&gt; b) -&gt; [a] -&gt; [b]
</span><a href="../../base/src/GHC.Base.html#map"><span class="hs-identifier hs-var">map</span></a></span><span> </span><span class="annot"><span class="annottext">GhcEnvironmentFileEntry -&gt; String
</span><a href="Distribution.Simple.GHC.Internal.html#renderGhcEnvironmentFileEntry"><span class="hs-identifier hs-var">renderGhcEnvironmentFileEntry</span></a></span><span>
</span><span id="line-666"></span><span>
</span><span id="line-667"></span><span class="hs-comment">-- | Render an individual GHC environment file entry</span><span>
</span><span id="line-668"></span><span class="hs-comment">--</span><span>
</span><span id="line-669"></span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#renderGhcEnvironmentFileEntry"><span class="hs-identifier hs-type">renderGhcEnvironmentFileEntry</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#GhcEnvironmentFileEntry"><span class="hs-identifier hs-type">GhcEnvironmentFileEntry</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="../../base/src/GHC.Base.html#String"><span class="hs-identifier hs-type">String</span></a></span><span>
</span><span id="line-670"></span><span id="renderGhcEnvironmentFileEntry"><span class="annot"><span class="annottext">renderGhcEnvironmentFileEntry :: GhcEnvironmentFileEntry -&gt; String
</span><a href="Distribution.Simple.GHC.Internal.html#renderGhcEnvironmentFileEntry"><span class="hs-identifier hs-var hs-var">renderGhcEnvironmentFileEntry</span></a></span></span><span> </span><span id="local-6989586621679716645"><span class="annot"><span class="annottext">GhcEnvironmentFileEntry
</span><a href="#local-6989586621679716645"><span class="hs-identifier hs-var">entry</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="hs-keyword">case</span><span> </span><span class="annot"><span class="annottext">GhcEnvironmentFileEntry
</span><a href="#local-6989586621679716645"><span class="hs-identifier hs-var">entry</span></a></span><span> </span><span class="hs-keyword">of</span><span>
</span><span id="line-671"></span><span>    </span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#GhcEnvFileComment"><span class="hs-identifier hs-type">GhcEnvFileComment</span></a></span><span>   </span><span id="local-6989586621679716644"><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716644"><span class="hs-identifier hs-var">comment</span></a></span></span><span>   </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">String -&gt; String
</span><a href="#local-6989586621679716643"><span class="hs-identifier hs-var">format</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716644"><span class="hs-identifier hs-var">comment</span></a></span><span>
</span><span id="line-672"></span><span>      </span><span class="hs-keyword">where</span><span> </span><span id="local-6989586621679716643"><span class="annot"><span class="annottext">format :: String -&gt; String
</span><a href="#local-6989586621679716643"><span class="hs-identifier hs-var hs-var">format</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; [String] -&gt; String
forall a. [a] -&gt; [[a]] -&gt; [a]
</span><a href="../../base/src/Data.OldList.html#intercalate"><span class="hs-identifier hs-var">intercalate</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;\n&quot;</span></span><span> </span><span class="annot"><span class="annottext">([String] -&gt; String) -&gt; (String -&gt; [String]) -&gt; String -&gt; String
forall b c a. (b -&gt; c) -&gt; (a -&gt; b) -&gt; a -&gt; c
</span><a href="../../base/src/GHC.Base.html#."><span class="hs-operator hs-var">.</span></a></span><span> </span><span class="annot"><span class="annottext">(String -&gt; String) -&gt; [String] -&gt; [String]
forall a b. (a -&gt; b) -&gt; [a] -&gt; [b]
</span><a href="../../base/src/GHC.Base.html#map"><span class="hs-identifier hs-var">map</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;--&quot;</span></span><span> </span><span class="annot"><span class="annottext">String -&gt; String -&gt; String
</span><a href="#local-6989586621679716642"><span class="hs-operator hs-var">&lt;++&gt;</span></a></span><span class="hs-special">)</span><span> </span><span class="annot"><span class="annottext">([String] -&gt; [String])
-&gt; (String -&gt; [String]) -&gt; String -&gt; [String]
forall b c a. (b -&gt; c) -&gt; (a -&gt; b) -&gt; a -&gt; c
</span><a href="../../base/src/GHC.Base.html#."><span class="hs-operator hs-var">.</span></a></span><span> </span><span class="annot"><span class="annottext">String -&gt; [String]
</span><a href="../../base/src/Data.OldList.html#lines"><span class="hs-identifier hs-var">lines</span></a></span><span>
</span><span id="line-673"></span><span>            </span><span id="local-6989586621679716641"><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716641"><span class="hs-identifier hs-var">pref</span></a></span></span><span> </span><span id="local-6989586621679716642"><span class="annot"><span class="annottext">&lt;++&gt; :: String -&gt; String -&gt; String
</span><a href="#local-6989586621679716642"><span class="hs-operator hs-var hs-var">&lt;++&gt;</span></a></span></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;&quot;</span></span><span>  </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716641"><span class="hs-identifier hs-var">pref</span></a></span><span>
</span><span id="line-674"></span><span>            </span><span id="local-6989586621679716640"><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716640"><span class="hs-identifier hs-var">pref</span></a></span></span><span> </span><span class="annot"><a href="#local-6989586621679716642"><span class="hs-operator hs-var">&lt;++&gt;</span></a></span><span> </span><span id="local-6989586621679716639"><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716639"><span class="hs-identifier hs-var">str</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716640"><span class="hs-identifier hs-var">pref</span></a></span><span> </span><span class="annot"><span class="annottext">String -&gt; String -&gt; String
forall a. [a] -&gt; [a] -&gt; [a]
</span><a href="../../base/src/GHC.Base.html#%2B%2B"><span class="hs-operator hs-var">++</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot; &quot;</span></span><span> </span><span class="annot"><span class="annottext">String -&gt; String -&gt; String
forall a. [a] -&gt; [a] -&gt; [a]
</span><a href="../../base/src/GHC.Base.html#%2B%2B"><span class="hs-operator hs-var">++</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716639"><span class="hs-identifier hs-var">str</span></a></span><span>
</span><span id="line-675"></span><span>    </span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#GhcEnvFilePackageId"><span class="hs-identifier hs-type">GhcEnvFilePackageId</span></a></span><span> </span><span id="local-6989586621679716638"><span class="annot"><span class="annottext">UnitId
</span><a href="#local-6989586621679716638"><span class="hs-identifier hs-var">pkgid</span></a></span></span><span>     </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;package-id &quot;</span></span><span> </span><span class="annot"><span class="annottext">String -&gt; String -&gt; String
forall a. [a] -&gt; [a] -&gt; [a]
</span><a href="../../base/src/GHC.Base.html#%2B%2B"><span class="hs-operator hs-var">++</span></a></span><span> </span><span class="annot"><span class="annottext">UnitId -&gt; String
forall a. Pretty a =&gt; a -&gt; String
</span><a href="Distribution.Pretty.html#prettyShow"><span class="hs-identifier hs-var">prettyShow</span></a></span><span> </span><span class="annot"><span class="annottext">UnitId
</span><a href="#local-6989586621679716638"><span class="hs-identifier hs-var">pkgid</span></a></span><span>
</span><span id="line-676"></span><span>    </span><span class="annot"><a href="Distribution.Simple.GHC.Internal.html#GhcEnvFilePackageDb"><span class="hs-identifier hs-type">GhcEnvFilePackageDb</span></a></span><span> </span><span id="local-6989586621679716637"><span class="annot"><span class="annottext">PackageDB
</span><a href="#local-6989586621679716637"><span class="hs-identifier hs-var">pkgdb</span></a></span></span><span>     </span><span class="hs-glyph">-&gt;</span><span>
</span><span id="line-677"></span><span>      </span><span class="hs-keyword">case</span><span> </span><span class="annot"><span class="annottext">PackageDB
</span><a href="#local-6989586621679716637"><span class="hs-identifier hs-var">pkgdb</span></a></span><span> </span><span class="hs-keyword">of</span><span>
</span><span id="line-678"></span><span>        </span><span class="annot"><span class="annottext">PackageDB
</span><a href="Distribution.Simple.Compiler.html#GlobalPackageDB"><span class="hs-identifier hs-var">GlobalPackageDB</span></a></span><span>           </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;global-package-db&quot;</span></span><span>
</span><span id="line-679"></span><span>        </span><span class="annot"><span class="annottext">PackageDB
</span><a href="Distribution.Simple.Compiler.html#UserPackageDB"><span class="hs-identifier hs-var">UserPackageDB</span></a></span><span>             </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;user-package-db&quot;</span></span><span>
</span><span id="line-680"></span><span>        </span><span class="annot"><a href="Distribution.Simple.Compiler.html#SpecificPackageDB"><span class="hs-identifier hs-type">SpecificPackageDB</span></a></span><span> </span><span id="local-6989586621679716633"><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716633"><span class="hs-identifier hs-var">dbfile</span></a></span></span><span>  </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;package-db &quot;</span></span><span> </span><span class="annot"><span class="annottext">String -&gt; String -&gt; String
forall a. [a] -&gt; [a] -&gt; [a]
</span><a href="../../base/src/GHC.Base.html#%2B%2B"><span class="hs-operator hs-var">++</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679716633"><span class="hs-identifier hs-var">dbfile</span></a></span><span>
</span><span id="line-681"></span><span>    </span><span class="annot"><span class="annottext">GhcEnvironmentFileEntry
</span><a href="Distribution.Simple.GHC.Internal.html#GhcEnvFileClearPackageDbStack"><span class="hs-identifier hs-var">GhcEnvFileClearPackageDbStack</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;clear-package-db&quot;</span></span><span>
</span><span id="line-682"></span></pre></body></html>